[PATCH 05/14] qapi/doc.py: Assert no suffix given for enum members

John Snow posted 14 patches 5 years, 4 months ago
There is a newer version of this series
[PATCH 05/14] qapi/doc.py: Assert no suffix given for enum members
Posted by John Snow 5 years, 4 months ago
We don't do anything with this argument. If something shows up here,
something wrong has happened.

Signed-off-by: John Snow <jsnow@redhat.com>
---
 scripts/qapi/doc.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/scripts/qapi/doc.py b/scripts/qapi/doc.py
index 62b8f34707..9a02cf2f27 100644
--- a/scripts/qapi/doc.py
+++ b/scripts/qapi/doc.py
@@ -141,6 +141,7 @@ def texi_if(ifcond, prefix='\n', suffix='\n'):
 def texi_enum_value(value, desc, suffix):
     """Format a table of members item for an enumeration value"""
     assert isinstance(value, QAPISchemaEnumMember)
+    assert suffix == '', "Ignored suffix for texi_enum_value"
     return '@item @code{%s}\n%s%s' % (
         value.name, desc, texi_if(value.ifcond, prefix='@*'))
 
-- 
2.26.2


Re: [PATCH 05/14] qapi/doc.py: Assert no suffix given for enum members
Posted by Eduardo Habkost 5 years, 4 months ago
On Tue, Sep 22, 2020 at 05:17:53PM -0400, John Snow wrote:
> We don't do anything with this argument. If something shows up here,
> something wrong has happened.
> 
> Signed-off-by: John Snow <jsnow@redhat.com>

Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>

-- 
Eduardo