We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 36f2d77 commit f056fa6Copy full SHA for f056fa6
Doc/library/stdtypes.rst
@@ -5871,6 +5871,16 @@ Frozen dictionaries
5871
:class:`!frozendict` is not a :class:`!dict` subclass but inherits directly
5872
from ``object``.
5873
5874
+ .. classmethod:: fromkeys(iterable, value=None, /)
5875
+
5876
+ Create a new frozen dictionary with keys from *iterable* and values set to
5877
+ *value*.
5878
5879
+ :meth:`fromkeys` is a class method that returns a new frozen dictionary.
5880
+ *value* defaults to ``None``. All of the values refer to just a single
5881
+ instance, so it generally doesn't make sense for *value* to be a mutable
5882
+ object such as an empty list.
5883
5884
.. versionadded:: next
5885
5886
0 commit comments