Re: Understanding Python's interpreter

2007-04-07 Thread Rafael Almeida
On Sat, 07 Apr 2007 04:35:49 +0200 Gabriel Genellina <[EMAIL PROTECTED]> wrote: > Speed? Eficiency? File size? Ease of use? > A .pyc *could* be written in ASCII, but what do you gain? Replacing a > few trivial functions in the Python core with a printf/scanf equivalent? > At the same time you

Understanding Python's interpreter

2007-04-06 Thread Rafael Almeida
Hello, I'm studying compilers now on my university and I can't quite understand one thing about the python interpreter. Why is its input a binary file (pyc)? The LOAD_CONST opcode is 100 (dec) and STORE_FAST's is 125 (dec). The translation of the following code: foo.py: x = 10 Could be t