chiark / gitweb /
documentation/python: minor.
authorVladimír Vondruš <mosra@centrum.cz>
Sun, 2 Jan 2022 12:09:48 +0000 (13:09 +0100)
committerVladimír Vondruš <mosra@centrum.cz>
Sun, 2 Jan 2022 16:23:42 +0000 (17:23 +0100)
Those values are already available, so don't calculate them again.

documentation/python.py

index ce35d81eff8eab36a7a959f65913f3c86915c049..62f2f7949076329ac7ac62ad9bb3ee60c79b805b 100755 (executable)
@@ -1406,7 +1406,7 @@ def extract_function_doc(state: State, parent, entry: Empty) -> List[Any]:
         overloads = []
         for name, summary, args, type, type_link in funcs:
             out = Empty()
-            out.name = entry.path[-1]
+            out.name = name
             out.params = []
             out.has_complex_params = False
             out.has_details = False
@@ -2590,7 +2590,7 @@ def run(basedir, config, *, templates=default_templates, search_add_lookahead_ba
         index_entry = Empty()
         index_entry.kind = 'page'
         index_entry.name = entry.name
-        index_entry.url = config['URL_FORMATTER'](entry.type, entry.path)[1]
+        index_entry.url = entry.url
         index_entry.summary = entry.summary
         index_entry.has_nestable_children = False
         index_entry.children = []