Reason why co_filename is no longer interned?
David Christian
david.christian at gmail.com
Sun Mar 1 20:03:37 EST 2009
In 2005, when the ast branch was merged to head, compile.c
when setting the filename for the code object,
PyString_InternFromString was replaced with PyString_FromString.
http://svn.python.org/view?view=rev&revision=39758
This means that where before, you could rely that
<function>.func_code.co_filename == <function1>.func_code.co_filename
Does anyone know whether this change was purposeful?
More information about the Python-list
mailing list