Hi On Tue, Aug 25, 2026 at 3:35 PM Markus Armbruster <[email protected]> wrote: > > Marc-André Lureau <[email protected]> writes: > > > Hi > > > > On Fri, Aug 21, 2026 at 5:41 PM Markus Armbruster <[email protected]> wrote: > >> > >> Marc-André Lureau <[email protected]> writes: > >> > >> > Introduce a minimal struct that pairs a QAPI type's internal name with > >> > its "masked" introspection name. Generated constants of this type will > >> > let QOM property registration carry a reliable reference to the QAPI > >> > schema and possibly other associated data. > >> > > >> > The fields are populated in following commits. > >> > > >> > Signed-off-by: Marc-André Lureau <[email protected]> > >> > --- > >> > include/qapi/qapi-type-info.h | 32 ++++++++++++++++++++++++++++++++ > >> > 1 file changed, 32 insertions(+) > >> > > >> > diff --git a/include/qapi/qapi-type-info.h > >> > b/include/qapi/qapi-type-info.h > >> > new file mode 100644 > >> > index 000000000000..97eb1d7bf490 > >> > --- /dev/null > >> > +++ b/include/qapi/qapi-type-info.h > >> > @@ -0,0 +1,32 @@ > >> > +/* > >> > + * SPDX-License-Identifier: GPL-2.0-or-later > >> > + */ > >> > + > >> > +#ifndef QAPI_TYPE_INFO_H > >> > +#define QAPI_TYPE_INFO_H > >> > + > >> > +#include "qapi/util.h" > >> > + > >> > +/** > >> > + * QAPITypeInfo - QAPI type metadata > >> > + * > >> > + * @name: QAPI type name (e.g. "str", "OnOffAuto", "int32List"). > >> > + * QOM uses this as the property type string. > >> > + * @masked_name: Name of the type in the QAPI introspection schema, > >> > assigned by > >> > + * scripts/qapi code generator (e.g. "368"). > >> > >> Suggest 'Name of the type in output of query-qmp-schema (e.g. "368")'. > >> > > > > ok > > > >> > + * NULL for implicit types. > >> > >> Can this happen? I can't see any QAPITypeInfo with null @masked_name at > >> the end of the series. > > > > It's still optional, but it's true that at the end of the series it > > should be set for all generated type infos. Let's just say "or NULL if > > unavailable" ? > > I can't find a QAPITypeInfo without @masked_name at any point in the > series. > > Either it cannot happen. Then the comment shouldn't suggest it can. > > Or it can happen, but doesn't with the current schema. Then I'd like to > have know how it could happen. Any ideas?
Manual QAPITypeInfo, like util/uuid.c. I used to have masked_name omitted. I added it in the new versions. But it is still optional in introspection. Do you think it should be mandatory?
