[Python-Dev] undesireable unpickle behavior, proposed fix

"Martin v. Löwis" martin at v.loewis.de
Tue Jan 27 20:40:06 CET 2009


> Hm. This would change the pickling format though. Wouldn't just
> interning (short) strings on unpickling be simpler?

Sure - that's what Jake had proposed. However, it is always difficult
to select which strings to intern - his heuristics (IIUC) is to intern
all strings that appear as dictionary keys. Whether this is good enough,
I don't know. In particular, it might intern very large strings that
aren't identifiers at all.

Regards,
Martin


More information about the Python-Dev mailing list