diff options
author | Tarja Sundqvist <[email protected]> | 2024-11-08 15:36:12 +0200 |
---|---|---|
committer | Tarja Sundqvist <[email protected]> | 2024-11-08 15:36:12 +0200 |
commit | abe4729ea8db32124c36dc33fc32eb629df03043 (patch) | |
tree | 6c02a1174b4abbcec9a127758b2c406975661312 /src/qml/jsruntime/qv4module.cpp | |
parent | 7c32569ad27b743b6cb50e2bcb67c9ca1674f238 (diff) | |
parent | 7550f26e156b3bca5f4b6a9711352c2aa0ba8463 (diff) |
Merge tag 'v5.15.16-lts' into tqtc/lts-5.15-opensourcev5.15.16-lts-lgpl
Qt 5.15.16-lts release
Change-Id: I2892ad4097deaec565b10357ca61be10048a7c81
Diffstat (limited to 'src/qml/jsruntime/qv4module.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4module.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/qml/jsruntime/qv4module.cpp b/src/qml/jsruntime/qv4module.cpp index 08a1900383..8f148994e3 100644 --- a/src/qml/jsruntime/qv4module.cpp +++ b/src/qml/jsruntime/qv4module.cpp @@ -258,9 +258,12 @@ OwnPropertyKeyIterator *Module::virtualOwnPropertyKeys(const Object *o, Value *t if (module->d()->unit->isESModule()) { names = module->d()->unit->exportedNames(); } else { - Heap::InternalClass *scopeClass = module->d()->scope->internalClass; - for (uint i = 0; i < scopeClass->size; ++i) - names << scopeClass->keyAt(i); + QV4::Scope scope(module->engine()); + QV4::Scoped<InternalClass> scopeClass(scope, module->d()->scope->internalClass); + for (uint i = 0, end = scopeClass->d()->size; i < end; ++i) { + QV4::ScopedValue key(scope, scopeClass->d()->keyAt(i)); + names << key->toQString(); + } } return new ModuleNamespaceIterator(names); |