chiark / gitweb /
Doc++
authorVladimír Vondruš <mosra@centrum.cz>
Sun, 7 Jul 2019 20:12:13 +0000 (22:12 +0200)
committerVladimír Vondruš <mosra@centrum.cz>
Sun, 7 Jul 2019 20:20:53 +0000 (22:20 +0200)
documentation/doxygen.py
documentation/python.py

index c765f4302df36d7e24f61b022ebda0dfcd42426d..82b787354d5e927ea1ff78254caaecf0417b7376 100755 (executable)
@@ -3811,8 +3811,8 @@ def run(doxyfile, templates=default_templates, wildcard=default_wildcard, index_
                     f.write(rendered.encode('utf-8'))
                     # Add back a trailing newline so we don't need to bother
                     # with patching test files to include a trailing newline to
-                    # make Git happy
-                    # TODO could keep_trailing_newline fix this better?
+                    # make Git happy. Can't use keep_trailing_newline because
+                    # that'd add it also for nested templates :(
                     f.write(b'\n')
         else:
             parsed = parse_xml(state, file)
@@ -3829,8 +3829,8 @@ def run(doxyfile, templates=default_templates, wildcard=default_wildcard, index_
                 f.write(rendered.encode('utf-8'))
                 # Add back a trailing newline so we don't need to bother with
                 # patching test files to include a trailing newline to make Git
-                # happy
-                # TODO could keep_trailing_newline fix this better?
+                # happy. Can't use keep_trailing_newline because that'd add it
+                # also for nested templates :(
                 f.write(b'\n')
 
     # Empty index page in case no mainpage documentation was provided so
@@ -3854,8 +3854,8 @@ def run(doxyfile, templates=default_templates, wildcard=default_wildcard, index_
             f.write(rendered.encode('utf-8'))
             # Add back a trailing newline so we don't need to bother with
             # patching test files to include a trailing newline to make Git
-            # happy
-            # TODO could keep_trailing_newline fix this better?
+            # happy. Can't use keep_trailing_newline because that'd add it
+            # also for nested templates :(
             f.write(b'\n')
 
     if not state.doxyfile['M_SEARCH_DISABLED']:
@@ -3881,8 +3881,8 @@ def run(doxyfile, templates=default_templates, wildcard=default_wildcard, index_
                 f.write(rendered.encode('utf-8'))
                 # Add back a trailing newline so we don't need to bother with
                 # patching test files to include a trailing newline to make Git
-                # happy
-                # TODO could keep_trailing_newline fix this better?
+                # happy. Can't use keep_trailing_newline because that'd add it
+                # also for nested templates :(
                 f.write(b'\n')
 
     # Copy all referenced files
index acf2b65f4d206ef84e71475545651d4e499e8b37..29121f32ab7801727bd83a6ab9c72a2ef04e33c2 100755 (executable)
@@ -356,8 +356,8 @@ def render(config, template: str, page, env: jinja2.Environment):
         f.write(rendered.encode('utf-8'))
         # Add back a trailing newline so we don't need to bother with
         # patching test files to include a trailing newline to make Git
-        # happy
-        # TODO could keep_trailing_newline fix this better?
+        # happy. Can't use keep_trailing_newline because that'd add it
+        # also for nested templates :(
         f.write(b'\n')
 
 def extract_module_doc(state: State, path: List[str], module):
@@ -1179,8 +1179,8 @@ def run(basedir, config, templates):
             f.write(rendered.encode('utf-8'))
             # Add back a trailing newline so we don't need to bother with
             # patching test files to include a trailing newline to make Git
-            # happy
-            # TODO could keep_trailing_newline fix this better?
+            # happy. Can't use keep_trailing_newline because that'd add it
+            # also for nested templates :(
             f.write(b'\n')
 
     # Create index.html if it was not provided by the user