Skip to content

Commit fd75adf

Browse files
committed
Do not draw comparisons between Literal and Union
1 parent 57b32a4 commit fd75adf

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

Doc/library/typing.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1228,8 +1228,7 @@ These can be used as types in annotations. They all support subscription using
12281228
is allowed as type argument to ``Literal[...]``, but type checkers may
12291229
impose restrictions. See :pep:`586` for more details about literal types.
12301230

1231-
``Literal`` is very similar to :class:`Union`, the main difference is that its
1232-
arguments are literal values instead of types:
1231+
Additional details:
12331232

12341233
* The arguments must be literal values and there must be at least one.
12351234

0 commit comments

Comments
 (0)