[Python-Dev] Re: Making mutable objects readonly

Tim Peters tim.one@home.com
Mon, 29 Jan 2001 22:18:47 -0500


Note that even adding a "frozen" flag would add 4 bytes to every freezable
object on most machines.  That's why I'd rather .freeze() replace the type
pointer and .unfreeze() restore it.  No time or space overhead; no
cluttering up the normal-case (i.e., unfrozen) type implementations with new
tests.