11 Oct
2018
11 Oct
'18
3:45 p.m.
On Fri, Oct 12, 2018 at 2:41 AM Chris Barker - NOAA Federal via
Python-ideas
This violates the Liskov Substitution Principle.
If we REALLY had a time machine, then dict would subclass frozendict, and we’d be all set.
Thanks to virtual subclassing, we can still do this. The question is, should we? Intuition tells me that a frozen dictionary is a form of dictionary that adds restrictions, not that a dictionary is a frozen dictionary that you left out to thaw. But as we see from [frozen]set, it's probably best to treat them as completely independent classes, both implementing the basic Mapping interface. ChrisA