PEP 312 (and thus 308) implemented with a black magic trick

Michael Hudson mwh at python.net
Tue Mar 18 13:27:10 CET 2003


mis6 at pitt.edu (Michele Simionato) writes:

> Today I had an illumination on how to implement both PEP 312 and 308
> in current Python. I think I will share the idea, even if I would *not* 
> recommend to use such a dirty trick in production code.

Do you know about my bytecodehacks?  They might appeal to your
hackerish instincts...

I once proposed an "explosive license" for things like this: if you
use them in production code, your shoes explode.

Cheers,
M.

-- 
42. You can measure a programmer's perspective by noting his
    attitude on the continuing vitality of FORTRAN.
  -- Alan Perlis, http://www.cs.yale.edu/homes/perlis-alan/quotes.html




More information about the Python-list mailing list