Python Compiler

mlauer at trollinger-fe.rz.uni-frankfurt.de mlauer at trollinger-fe.rz.uni-frankfurt.de
Tue May 2 13:25:19 CEST 2000


Cedric Adjih (adjih at crepuscule.com) wrote:
> Josh Tompkins <josht at iname.com> wrote:
> > This is maybe a dumb question, but here goes: (donning asbestos underwear)

> > What would be the difficulty of writing a real python compiler?  Or maybe a 
> > compiler/interpreter similar to the one in VB?  Leaving platform indepenacy 
> > and other similar concerns aside, what are the technical hurdles?  Is it 
> > hard to write a compiler?  Given proper pointers to tutorials and 
> > references I'd give it a shot, if it wasn't above my (low) level of 
> > programming skill...

>   The main problem I think is that Python data-structures are not
> very well suited to compilation. Where one would have used 
> a C fixed array, Python programs would use a list, appending each time.
> The poor compiler would have to guess whether all the elements are
> of the same type, and whether the number of elements is fixed and
> computable, and whether there are funky operations like a[1:5]=[None]. 

Wouldn"t this be much less of a problem when using C++/STL as the
target language ?

--
--
    Regards & Gruesse from Mickey @ http://www.Vanille.de
  ---------------------------------------------------------
  How could anyone know me - when I don't even know myself ?





More information about the Python-list mailing list