xemu/scripts
Eric Blake 25a0d9c977 qapi: Use predicate callback to determine visit filtering
Previously, qapi-types and qapi-visit filtered out implicit
objects during visit_object_type() by using 'info' (works since
implicit objects do not [yet] have associated info); meanwhile
qapi-introspect filtered out all schema types on the first pass
by returning a python type from visit_begin(), which was then
used at a distance in QAPISchema.visit() to do the filtering.

Rather than keeping these ad hoc approaches, add a new visitor
callback visit_needed() which returns False to skip a given
entity, and which defaults to True unless overridden.  Use the
new mechanism to simplify all three filtering visitors.

No change to the generated code.

Suggested-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <1444710158-8723-2-git-send-email-eblake@redhat.com>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
2015-10-15 08:39:07 +02:00
..
2015-03-10 10:49:25 +01:00
2015-09-04 13:18:04 +02:00
2014-02-20 13:14:18 +01:00
2012-03-30 08:14:11 -05:00
2015-10-12 18:44:54 +02:00
2015-10-12 18:46:50 +02:00
2015-02-16 15:07:18 +00:00
2012-04-16 15:41:20 +02:00
2014-02-15 16:10:25 +04:00
2012-03-24 14:10:25 +00:00
2014-06-09 15:43:40 +02:00