carshing the interpreter in two lines
Mel Wilson
mwilson-to at sympatico.ca
Sat Jun 3 14:11:54 EDT 2006
sam wrote:
> tomer:
>
> It is my opinion that you would loose performance if the Python
> interpreter had the additional task of verifying byte code. It might be
> more appropriate to have a preprocessor that did the verifying as it
> compiled the byte code.
Possibly. A good book on the topic is Douglas Hofstadter's
_Goedel, Escher, Bach: an Eternal Golden Braid_.
Particularly starting from the chapter "Contracrostipunctus".
Cheers, Mel.
> Sam Schulenburg
>
> gangesmaster wrote:
>> the following (random) code crashes my interpreter
>> (python 2.4.3/winxp):
>>
>> from types import CodeType as code
>> exec code(0, 5, 8, 0, "hello moshe", (), (), (), "", "", 0, "")
>>
>> i would expect the interpreter to do some verifying, at least for
>> sanity (valid opcodes, correct stack size, etc.) before executing
>> artbitrary code... after all, it was the BDFL who said """I'm not
>> saying it's uncrashable. I'm saying that if you crash it, it's a
>> bug unless proven harebrained."""
>>
>>
>> -tomer
>
More information about the Python-list
mailing list