We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
TypedDict
NamedTuple
class
1 parent 3c8c4e9 commit ac0925dCopy full SHA for ac0925d
1 file changed
Doc/library/typing.rst
@@ -2355,7 +2355,7 @@ These functions and classes should not be used directly as annotations.
2355
Their intended purpose is to be building blocks for creating and declaring
2356
types.
2357
2358
-.. function:: NamedTuple
+.. class:: NamedTuple
2359
2360
Typed version of :func:`collections.namedtuple`.
2361
@@ -2588,7 +2588,7 @@ types.
2588
for more details.
2589
2590
2591
-.. function:: TypedDict
+.. class:: TypedDict(dict)
2592
2593
Special construct to add type hints to a dictionary.
2594
At runtime ":class:`!TypedDict` instances" are simply :class:`dicts <dict>`.
0 commit comments