Hi

On Wed, Jul 29, 2026 at 2:04 PM Marc-André Lureau
<[email protected]> wrote:
>
> Hi
>
> On Wed, Jul 29, 2026 at 11:29 AM Markus Armbruster via qemu
> development <[email protected]> wrote:
> > > Along the way, a few pre-existing type mismatches in property
> > > definitions are fixed, the "struct tm" RTC property is replaced with a
> > > proper QAPI StructTm type etc. Introducing more specific types or a
> > > "typedef" to QAPI could help provide better associated type informations
> > > than plain "str" in many cases, for example.
> >
> > Examples?
> >
>
> Properties using str_type_info that carry structured values with their
> own validation: macaddr ("52:54:00:12:34:56"), PCI addresses
> ("04:00.0"), netdev names, chardev names, drive names, UUID strings. A
> QAPI "typedef" (or newtype) for e.g. MacAddr, PciDevAddr, UUID could
> let tools know these aren't arbitrary strings (see "hw/nvdimm: convert
> UUID property to QAPI-aware registration" patch).

On a related note, qapi-type for integers are all collapsed to "int"
(and list of). Even though json wire accepts "int", it would be nice
to retain the original type information.

Reply via email to