Message 274311 - Python tracker (original) (raw)
Hmm... so if I read you right:
IntFlags is not simply the meet of int and Flags (like IntEnum is the meet of int and Enum, https://docs.python.org/3.5/library/enum.html#others)? It seems a very different class.
(more important) If I give names to 1, 3, 4, and 6, you're in fact saying that MyFlags(7) == MyFlags(5) (since 2 is never set)? Seems like succumbing to temptation to guess. ;-/ But maybe it's not bad in this case, since there is really no ambiguity.