ITADN

Why are the type parameters `set`, `frozenset`, `dict` and `frozendict` are generic in unbounded?

#15751Openjonathandung 创建于 2026-05-10
J
jonathandungcommented
Excuse me if this question may come across as stupid, but these hashed containers should only have hashable items. However, in `builtins.pyi`, I see that their type variables do not have an upper bound of `collections.abc.Hashable`. How is that so?
1 条评论