mirror of
https://github.com/yuzu-emu/unicorn.git
synced 2024-12-24 00:25:42 +00:00
eddfb13c2c
Currently the ObjectProperty iterator API works as follows: ObjectPropertyIterator *iter; iter = object_property_iter_init(obj); while ((prop = object_property_iter_next(iter))) { ... } object_property_iter_free(iter); This has the benefit that the ObjectPropertyIterator struct can be opaque, but has the downside that callers need to explicitly call a free function. It is also not in keeping with iterator style used elsewhere in QEMU/GLib2. This patch changes the API to use stack allocation instead: ObjectPropertyIterator iter; object_property_iter_init(&iter, obj); while ((prop = object_property_iter_next(&iter))) { ... } Backports commit 7746abd8e9ee9db20c0b0fdb19504f163ba3cbea from qemu |
||
---|---|---|
.. | ||
cpu.h | ||
object.h | ||
qom-qobject.h |