diff options
author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2020-03-04 00:24:08 +0900 |
---|---|---|
committer | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2020-03-04 00:24:08 +0900 |
commit | 728c6cb5eeafc6448d76ea5174b5b565ef9935c7 (patch) | |
tree | 2c55f5b5ea851a29e21291528c92da814fe26a09 /sphinx/domains/python.py | |
parent | cdc7cc6fb3e2ade64149a5bed9b3b5be0132ce47 (diff) | |
download | sphinx-git-728c6cb5eeafc6448d76ea5174b5b565ef9935c7.tar.gz |
refactor: Update type annotation for python domain
Diffstat (limited to 'sphinx/domains/python.py')
-rw-r--r-- | sphinx/domains/python.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sphinx/domains/python.py b/sphinx/domains/python.py index c9c8d5704..a9edd85b4 100644 --- a/sphinx/domains/python.py +++ b/sphinx/domains/python.py @@ -1034,7 +1034,8 @@ class PythonDomain(Domain): self.modules[modname] = data def find_obj(self, env: BuildEnvironment, modname: str, classname: str, - name: str, type: str, searchmode: int = 0) -> List[Tuple[str, Any]]: + name: str, type: str, searchmode: int = 0 + ) -> List[Tuple[str, Tuple[str, str]]]: """Find a Python object for "name", perhaps using the given module and/or classname. Returns a list of (name, object entry) tuples. """ @@ -1045,7 +1046,7 @@ class PythonDomain(Domain): if not name: return [] - matches = [] # type: List[Tuple[str, Any]] + matches = [] # type: List[Tuple[str, Tuple[str, str]]] newname = None if searchmode == 1: |