diff options
author | Mårten Nordheim <marten.nordheim@qt.io> | 2024-05-02 23:46:32 +0200 |
---|---|---|
committer | Mårten Nordheim <marten.nordheim@qt.io> | 2024-05-06 16:52:05 +0200 |
commit | 23f983fa09aa378129ed34de8ab4c2ec95d18ab9 (patch) | |
tree | 99bebef3b96e2271afb2355b3897e6902e59c91b /tests/auto/corelib/plugin/quuid/test/CMakeLists.txt | |
parent | fd54b88d394447315df325f25d5ece2c1f1ca292 (diff) |
QMetaProperty: limit QMetaEnum resolution to enums known to QMetaType
Since we don't know ahead of time if a property's type is an enum
or a flag we have to resolve it at runtime.
In a QMetaProperty-heavy application this overhead can be quite dramatic
given that we mark anything that is not a built-in as a potential
flag/enum.
However, QMetaType already knows if it's an enum, so we can use that to
return early if it's not known to the meta-type system.
To add to this - Q_PROPERTY requires that a type is fully defined, so
there are no issues with forward declarations for the enums.
Change-Id: Ifecc7f1e6cdef416e3ce72ee705eb26e682071cc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'tests/auto/corelib/plugin/quuid/test/CMakeLists.txt')
0 files changed, 0 insertions, 0 deletions