Branching off #49, in what manner should duplicates be banned from dicts and multidicts?
Some potential options:
Error only when key1 == key2 and value1 == value2 (I think this one)
Error only when key1 == key2 but value1 != value2
Error when key1 == key2 regardless of values
I'm assuming we want both a new constructor and a new kwarg for each data type. Something like constructor immutabledict_from_unique_BLANK() and kwarg forbid_duplicate_BLANK where BLANK is either keys or items.
From past experience, there are situations when you would want to raise an exception in either of the last two cases; I have not encountered a situation where the first option is useful.
Branching off #49, in what manner should duplicates be banned from dicts and multidicts?
Some potential options:
key1 == key2
andvalue1 == value2
(I think this one)key1 == key2
butvalue1 != value2
key1 == key2
regardless of valuesI'm assuming we want both a new constructor and a new kwarg for each data type. Something like constructor
immutabledict_from_unique_BLANK()
and kwargforbid_duplicate_BLANK
whereBLANK
is eitherkeys
oritems
.