diff options
author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2019-07-13 23:29:38 +0900 |
---|---|---|
committer | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2019-07-13 23:46:17 +0900 |
commit | 0c48a28ad7216ee064b0db564745d749c049bfd5 (patch) | |
tree | 2bc2f13992c930c00bd3b60ea3e2c27c31e659cd /sphinx/ext/autosummary/generate.py | |
parent | 0bc530f1b7b3303e0f53e42010b629d67e79b835 (diff) | |
download | sphinx-git-0c48a28ad7216ee064b0db564745d749c049bfd5.tar.gz |
Fix type annotation for python 3.5.1
Diffstat (limited to 'sphinx/ext/autosummary/generate.py')
-rw-r--r-- | sphinx/ext/autosummary/generate.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sphinx/ext/autosummary/generate.py b/sphinx/ext/autosummary/generate.py index 2a23f1289..c4726f528 100644 --- a/sphinx/ext/autosummary/generate.py +++ b/sphinx/ext/autosummary/generate.py @@ -24,7 +24,7 @@ import pydoc import re import sys import warnings -from typing import Any, Callable, Dict, List, Set, Tuple, Type +from typing import Any, Callable, Dict, List, Set, Tuple from jinja2 import BaseLoader, FileSystemLoader, TemplateNotFound from jinja2.sandbox import SandboxedEnvironment @@ -44,6 +44,10 @@ from sphinx.util import rst from sphinx.util.inspect import safe_getattr from sphinx.util.osutil import ensuredir +if False: + # For type annotation + from typing import Type # for python3.5.1 + logger = logging.getLogger(__name__) |