qapi: Rename visitor parameter @variants to @alternatives
A previous commit narrowed the type of .visit_alternate_type() parameter @variants from QAPISchemaVariants to QAPISchemaAlternatives. Rename it to @alternatives. One of them passes @alternatives to helper function gen_visit_alternate(). Rename its @variants parameter to @alternatives as well. Signed-off-by: Markus Armbruster <armbru@redhat.com>
This commit is contained in:
@@ -371,11 +371,11 @@ class QAPISchemaGenTypeVisitor(QAPISchemaModularCVisitor):
|
||||
info: Optional[QAPISourceInfo],
|
||||
ifcond: QAPISchemaIfCond,
|
||||
features: List[QAPISchemaFeature],
|
||||
variants: QAPISchemaAlternatives) -> None:
|
||||
alternatives: QAPISchemaAlternatives) -> None:
|
||||
with ifcontext(ifcond, self._genh):
|
||||
self._genh.preamble_add(gen_fwd_object_or_array(name))
|
||||
self._genh.add(gen_object(name, ifcond, None,
|
||||
[variants.tag_member], variants))
|
||||
[alternatives.tag_member], alternatives))
|
||||
with ifcontext(ifcond, self._genh, self._genc):
|
||||
self._gen_type_cleanup(name)
|
||||
|
||||
|
Reference in New Issue
Block a user