Skip to content

Commit ddd1464

Browse files
committed
Document the dataclasses.field() change
1 parent 795dbdd commit ddd1464

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

Doc/library/dataclasses.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,10 @@ Module contents
333333
:attr:`!C.t` will be ``20``, and the class attributes :attr:`!C.x` and
334334
:attr:`!C.y` will not be set.
335335

336+
.. versionchanged:: next
337+
If *metadata* is ``None``, use an empty :class:`frozendict`, instead
338+
of a :func:`~types.MappingProxyType` of an empty :class:`dict`.
339+
336340
.. class:: Field
337341

338342
:class:`!Field` objects describe each defined field. These objects
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
:func:`dataclasses.field`: if *metadata* is ``None``, use an empty
2+
:class:`frozendict`, instead of a :func:`~types.MappingProxyType` of an
3+
empty :class:`dict`. Patch by Victor Stinner.

0 commit comments

Comments
 (0)