Skip to content

Commit d0830ee

Browse files
author
Markus Armbruster
committed
qapi: Use "not COND" instead of "!COND" for generated documentation
Generated documentation uses operators "and", "or", and "!". Change the latter to "not". Signed-off-by: Markus Armbruster <[email protected]> Message-Id: <[email protected]> Reviewed-by: Marc-André Lureau <[email protected]>
1 parent a798779 commit d0830ee

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

scripts/qapi/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ def cgen_ifcond(ifcond: Optional[Union[str, Dict[str, Any]]]) -> str:
233233

234234
def docgen_ifcond(ifcond: Optional[Union[str, Dict[str, Any]]]) -> str:
235235
# TODO Doc generated for conditions needs polish
236-
return gen_ifcond(ifcond, '%s', '!%s', ' and ', ' or ')
236+
return gen_ifcond(ifcond, '%s', 'not %s', ' and ', ' or ')
237237

238238

239239
def gen_if(cond: str) -> str:

tests/qapi-schema/doc-good.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ Features
174174
If
175175
~~
176176

177-
"!(IFONE or IFTWO)"
177+
"not (IFONE or IFTWO)"
178178

179179

180180
Another subsection

0 commit comments

Comments
 (0)