Skip to content

Commit 4e830ea

Browse files
committed
Fix inconsistent strict_optional documentation
1 parent 79a769a commit 4e830ea

2 files changed

Lines changed: 9 additions & 6 deletions

File tree

docs/source/command_line.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,8 @@ The following flags adjust how mypy handles values of type ``None``.
466466
.. warning::
467467

468468
``--no-strict-optional`` is evil. Avoid using it and definitely do
469-
not use it without understanding what it does.
469+
not use it without understanding what it does. See
470+
:ref:`Kinds of types <strict_optional>` for more information.
470471

471472

472473
.. _configuring-warnings:

docs/source/config_file.rst

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -618,15 +618,17 @@ section of the command line docs.
618618
:type: boolean
619619
:default: True
620620

621-
Effectively disables checking of optional
622-
types and ``None`` values. With this option, mypy doesn't
623-
generally check the use of ``None`` values -- it is treated
624-
as compatible with every type.
621+
Enables checking of optional types and ``None`` values.
622+
Setting this option to ``false`` effectively disables checking
623+
of optional types and ``None`` values. With
624+
``strict_optional = false``, mypy doesn't generally check the use
625+
of ``None`` values -- it is treated as compatible with every type.
625626

626627
.. warning::
627628

628629
``strict_optional = false`` is evil. Avoid using it and definitely do
629-
not use it without understanding what it does.
630+
not use it without understanding what it does. See
631+
:ref:`Kinds of types <strict_optional>` for more information.
630632

631633

632634
Configuring warnings

0 commit comments

Comments
 (0)