aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4runtimecodegen.cpp
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2025-01-24 15:30:16 +0100
committerUlf Hermann <ulf.hermann@qt.io>2025-02-04 16:49:20 +0100
commitc9778d2e9c41036cbd59976c51927d746bb78bcc (patch)
tree8d707606da595851d48f178f946c481bf290ce0a /src/qml/jsruntime/qv4runtimecodegen.cpp
parentc350c3888ec2a24e6d4cbf1d644a0867d4eabc67 (diff)
QtQml: Fix assignment of fileName and URL during compilation
We need to assign them right away when creating the module. If we do it later on, there are a lot of different code paths to cover and in fact we were missing some. Pick-to: 6.9 6.8 Task-number: QTBUG-133053 Change-Id: I57e381c787f504eb9bcd8c2041e41b4f1d1f8b53 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4runtimecodegen.cpp')
-rw-r--r--src/qml/jsruntime/qv4runtimecodegen.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/qml/jsruntime/qv4runtimecodegen.cpp b/src/qml/jsruntime/qv4runtimecodegen.cpp
index c7b05aeffe..65dc4a8c17 100644
--- a/src/qml/jsruntime/qv4runtimecodegen.cpp
+++ b/src/qml/jsruntime/qv4runtimecodegen.cpp
@@ -8,14 +8,10 @@
using namespace QV4;
using namespace QQmlJS;
-void RuntimeCodegen::generateFromFunctionExpression(const QString &fileName,
- const QString &sourceCode,
- AST::FunctionExpression *ast,
- Compiler::Module *module)
+void RuntimeCodegen::generateFromFunctionExpression(
+ const QString &sourceCode, AST::FunctionExpression *ast, Compiler::Module *module)
{
_module = module;
- _module->fileName = fileName;
- _module->finalUrl = fileName;
_context = nullptr;
Compiler::ScanFunctions scan(this, sourceCode, Compiler::ContextType::Global);