chiark / gitweb /
documentation/python: doc++
authorVladimír Vondruš <mosra@centrum.cz>
Sat, 13 Jul 2019 15:52:16 +0000 (17:52 +0200)
committerVladimír Vondruš <mosra@centrum.cz>
Sun, 14 Jul 2019 17:11:08 +0000 (19:11 +0200)
documentation/python.py

index 2e0362bc8b667804ea27e5d0ff17a2b63b225f01..b62e13155a37c161ef20ef6847e8b009f2e65cf9 100755 (executable)
@@ -847,7 +847,7 @@ def extract_function_doc(state: State, parent, path: List[str], function) -> Lis
             # TODO: external summary for functions
             out.summary = summary
 
-            # Don't show None return type for void functions
+            # Don't show None return type for functions w/o a return
             out.type = None if type == 'None' else type
             if out.type: out.type = make_name_link(state, path, out.type)
 
@@ -1372,6 +1372,8 @@ def run(basedir, config, templates):
             if urllib.parse.urlparse(path).netloc: return path
             path = [path]
         entry = state.name_map['.'.join(path)]
+        # TODO: this will blow up if linking to something that's not a module,
+        # class or a page
         return state.config['URL_FORMATTER'](entry.type, entry.path)[1]
 
     env.filters['basename_or_url'] = basename_or_url