On Mon, 15 Jun 2026 at 09:13, Daniel P. Berrangé <[email protected]> wrote:
> Do we know how many examples we have of embedding objects inside
> another ?
It is an extremely common pattern for device and SoC model
implementations; we've been recommending it for years.
> I would much prefer if we forbid the embedding of objects. It is
> horrible design practice to have some QOM objects which can be
> freed via reference count and some which cannot.
That would be a very large amount of code to rewrite to the
new paradigm. I don't object inherently ("you have pointers to
your child objects" works better when they might be implemented
in Rust and might play better with being able to create
machines and wire them up on the command line); I'm just
noting how much work it would be if you wanted to make
embedding forbidden.
thanks
-- PMM