aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4executablecompilationunit_p.h
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2024-01-08 14:03:06 +0100
committerUlf Hermann <ulf.hermann@qt.io>2024-01-13 16:03:59 +0100
commit2996fb835962750845702db4a9ded257f3f1a9b0 (patch)
treeb43a3aa62128ee22eb29715c9db6892db5be3381 /src/qml/jsruntime/qv4executablecompilationunit_p.h
parentc225e23e00bc539daefa357f687fe4a1b51ade9f (diff)
QtQml: Move property caches into base CU
Change-Id: I1567c9d3d61312e98200fb0854d7fcf111983948 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4executablecompilationunit_p.h')
-rw-r--r--src/qml/jsruntime/qv4executablecompilationunit_p.h19
1 files changed, 15 insertions, 4 deletions
diff --git a/src/qml/jsruntime/qv4executablecompilationunit_p.h b/src/qml/jsruntime/qv4executablecompilationunit_p.h
index d1504079b4..e0365b6fd8 100644
--- a/src/qml/jsruntime/qv4executablecompilationunit_p.h
+++ b/src/qml/jsruntime/qv4executablecompilationunit_p.h
@@ -78,12 +78,23 @@ public:
QUrl url() const { return m_compilationUnit->url(); }
QUrl finalUrl() const { return m_compilationUnit->finalUrl(); }
- // QML specific fields
- QQmlPropertyCacheVector propertyCaches;
- QQmlPropertyCache::ConstPtr rootPropertyCache() const { return propertyCaches.at(/*root object*/0); }
-
QQmlRefPointer<QQmlTypeNameCache> typeNameCache;
+ const QQmlPropertyCacheVector *propertyCachesPtr() const
+ {
+ return &m_compilationUnit->propertyCaches;
+ }
+
+ QQmlPropertyCacheVector *propertyCachesPtr()
+ {
+ return &m_compilationUnit->propertyCaches;
+ }
+
+ QQmlPropertyCache::ConstPtr rootPropertyCache() const
+ {
+ return m_compilationUnit->rootPropertyCache();
+ }
+
// mapping from component object index (CompiledData::Unit object index that points to component) to identifier hash of named objects
// this is initialized on-demand by QQmlContextData
QHash<int, IdentifierHash> namedObjectsPerComponentCache;