Why not a Python compiler?

Steve Holden steve at holdenweb.com
Fri Feb 8 00:27:37 CET 2008


Steven D'Aprano wrote:
> On Thu, 07 Feb 2008 09:06:32 -0500, Steve Holden wrote:
> 
>> Ryszard Szopa wrote:
>>> On Feb 5, 9:30 am, cokofree... at gmail.com wrote:
>>>
>>>> I don't know the exact details but I think the issue is the dynamic
>>>> nature of Python makes it impossible to correctly store the various
>>>> types and changes into compiled code. Someone else will probably be
>>>> able to provide a good reason as to why it isn't very feasible, nor a
>>>> good idea. If you want to speed up your python look at Psyco.
>>>> http://psyco.sourceforge.net/
>>> Yeah, but exactly what features make it so hard to write a compiler for
>>> Python?
>>> [...]
>> a. People tell me writing a compiler for Python is hard.
>>
>> b. It's certainly way to hard for me.
>>
>> c. But hey, I've heard about this neat language called Common Lisp that
>> has a compiler. It looks a lot like Python.
>>
>> d. So why can't you brainboxes write a compiler for Python?
>>
>> Please tell me if I'm missing anything from this summary of your thought
>> processes.
> 
> 
> Be fair -- he's asking what specific features of Python make it hard. 
> That's a reasonable question.
> 
> 
Bah, humbug. Maybe I should be getting more sleep ...

Fortunately someone less grumpy provided quite a decent answer.

regards
  Steve
-- 
Steve Holden        +1 571 484 6266   +1 800 494 3119
Holden Web LLC              http://www.holdenweb.com/




More information about the Python-list mailing list