diff options
| author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2018-11-11 18:44:30 +0900 |
|---|---|---|
| committer | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2018-11-11 18:44:30 +0900 |
| commit | c46c61fa3230529d607cf7993388a11238db3827 (patch) | |
| tree | f993107284715fd5a549ca699538d82d5fb9e8ff /sphinx/util/typing.py | |
| parent | 4c96c6efce9975919f0bdd675eff4f862c0beeae (diff) | |
| download | sphinx-git-c46c61fa3230529d607cf7993388a11238db3827.tar.gz | |
Fix type annotations for RoleFunction
Diffstat (limited to 'sphinx/util/typing.py')
| -rw-r--r-- | sphinx/util/typing.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sphinx/util/typing.py b/sphinx/util/typing.py index 609de302d..d31fa7c68 100644 --- a/sphinx/util/typing.py +++ b/sphinx/util/typing.py @@ -9,7 +9,7 @@ :license: BSD, see LICENSE for details. """ -from typing import Callable, Dict, List, Optional, Tuple +from typing import Callable, Dict, List, Tuple from docutils import nodes from docutils.parsers.rst.states import Inliner @@ -17,8 +17,7 @@ from six import text_type # common role functions -RoleFunction = Callable[[text_type, text_type, text_type, int, Inliner, - Optional[Dict], Optional[List[text_type]]], +RoleFunction = Callable[[text_type, text_type, text_type, int, Inliner, Dict, List[text_type]], Tuple[List[nodes.Node], List[nodes.Node]]] # title getter functions for enumerable nodes (see sphinx.domains.std) |
