From 7b42841ef9d3b3873ca4a62feb191e4debaa1aab Mon Sep 17 00:00:00 2001 From: Petr Kraus Date: Thu, 14 Mar 2024 10:18:29 +0100 Subject: [PATCH] Always generate failure code section (#2325) even for functions without any errors specified --- scripts/validitygenerator.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/validitygenerator.py b/scripts/validitygenerator.py index f9a9efc15..52bb3a3ab 100755 --- a/scripts/validitygenerator.py +++ b/scripts/validitygenerator.py @@ -290,6 +290,14 @@ def writeInclude(self, directory, basename, validity: ValidityCollection, write('On failure, this command returns::', file=fp) write('endif::doctype-manpage[]', file=fp) write(errorcodes, file=fp) + else: #no errorcodes + write('ifndef::doctype-manpage[]', file=fp) + write('<>::', file=fp) + write('None', file=fp) + write('endif::doctype-manpage[]', file=fp) + write('ifdef::doctype-manpage[]', file=fp) + write('This command does not return any failure codes::', file=fp) + write('endif::doctype-manpage[]', file=fp) write('****', file=fp) write('', file=fp)