[Python-Dev] PEP 351, the freeze protocol (original) (raw)

Raymond Hettinger raymond.hettinger at verizon.net
Mon Oct 24 17:49:35 CEST 2005


[Barry Warsaw]

I've had this PEP laying around for quite a few months. It was inspired by some code we'd written which wanted to be able to get immutable versions of arbitrary objects.

Unlike the PEP, the recipe works with older pythons and is trivially easy to extend to include other containers.

Overall, I'm -1 on the PEP. Like a bad C macro, the proposed abstraction hides too much. We lose critical distinctions of ordered vs unordered, mutable vs immutable, new objects vs in-place change, etc. Without compelling use cases, the mechanism smells like a hyper-generalization.

Raymond



More information about the Python-Dev mailing list