diff options
Diffstat (limited to 'sphinx/config.py')
-rw-r--r-- | sphinx/config.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sphinx/config.py b/sphinx/config.py index 652682168..82cf89a4e 100644 --- a/sphinx/config.py +++ b/sphinx/config.py @@ -17,6 +17,7 @@ from os import path, getenv from typing import ( Any, Callable, Dict, Generator, Iterator, List, NamedTuple, Set, Tuple, Union ) +from typing import TYPE_CHECKING from sphinx.deprecation import RemovedInSphinx40Warning from sphinx.errors import ConfigError, ExtensionError @@ -28,8 +29,7 @@ from sphinx.util.pycompat import execfile_ from sphinx.util.tags import Tags from sphinx.util.typing import NoneType -if False: - # For type annotation +if TYPE_CHECKING: from sphinx.application import Sphinx from sphinx.environment import BuildEnvironment |