diff options
Diffstat (limited to 'sphinx/util/compat.py')
-rw-r--r-- | sphinx/util/compat.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sphinx/util/compat.py b/sphinx/util/compat.py index f47237d11..42406afe7 100644 --- a/sphinx/util/compat.py +++ b/sphinx/util/compat.py @@ -20,13 +20,19 @@ from sphinx.deprecation import RemovedInSphinx17Warning docutils_version = tuple(int(x) for x in _du_version.split('.')[:2]) +if False: + # For type annotation + from typing import Any # NOQA + class _DeprecationWrapper(object): def __init__(self, mod, deprecated): + # type: (Any, Dict) -> None self._mod = mod self._deprecated = deprecated def __getattr__(self, attr): + # type: (str) -> Any if attr in self._deprecated: warnings.warn("sphinx.util.compat.%s is deprecated and will be " "removed in Sphinx 1.7, please use the standard " |