Skip to content

Commit 3393624

Browse files
Minor tweaks to typing union objects doc (GH-22741)
Automerge-Triggered-By: @merwok
1 parent 3f7e990 commit 3393624

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Doc/library/stdtypes.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4798,7 +4798,7 @@ type hinting syntax compared to :data:`typing.Union`.
47984798

47994799
.. describe:: isinstance(obj, union_object)
48004800

4801-
Calls to :func:`isinstance` are also supported with a Union object::
4801+
Calls to :func:`isinstance` are also supported with a union object::
48024802

48034803
>>> isinstance("", int | str)
48044804
True
@@ -4819,7 +4819,7 @@ type hinting syntax compared to :data:`typing.Union`.
48194819

48204820
.. describe:: issubclass(obj, union_object)
48214821

4822-
Calls to :func:`issubclass` are also supported with a Union Object.::
4822+
Calls to :func:`issubclass` are also supported with a union object::
48234823

48244824
>>> issubclass(bool, int | str)
48254825
True
@@ -4837,7 +4837,7 @@ type hinting syntax compared to :data:`typing.Union`.
48374837
File "<stdin>", line 1, in <module>
48384838
TypeError: issubclass() argument 2 cannot contain a parameterized generic
48394839

4840-
The type for the Union object is :data:`types.Union`. An object cannot be
4840+
The type of a union object is :data:`types.Union`. An object cannot be
48414841
instantiated from the type::
48424842

48434843
>>> import types

0 commit comments

Comments
 (0)