diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2014-03-03 08:36:32 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-04 15:22:58 +0100 |
commit | 94d003c59b346c078e4aa8233c29c2c2c3467e3b (patch) | |
tree | 798d926effa9f4de07d704494dd1639bb2bf9cb0 /src/qml/compiler/qqmltypecompiler.cpp | |
parent | 186f8e2f76dc6995d14e6632d9b9d704198feda2 (diff) |
[new compiler] Fix profiler support
Add profiler tracing calls during objection creation and make sure to set the
function token / source location correctly for the synthesized function
declarations of signal handlers.
Change-Id: Ie4f8accce3a5c5d1d57bb0646cda588b89b76718
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/compiler/qqmltypecompiler.cpp')
-rw-r--r-- | src/qml/compiler/qqmltypecompiler.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/qml/compiler/qqmltypecompiler.cpp b/src/qml/compiler/qqmltypecompiler.cpp index 6dcf15f24e..780b3dae36 100644 --- a/src/qml/compiler/qqmltypecompiler.cpp +++ b/src/qml/compiler/qqmltypecompiler.cpp @@ -1043,6 +1043,7 @@ bool SignalHandlerConverter::convertSignalHandlerExpressionsToFunctionDeclaratio QQmlJS::AST::FunctionBody *body = new (pool) QQmlJS::AST::FunctionBody(elements); QQmlJS::AST::FunctionDeclaration *functionDeclaration = new (pool) QQmlJS::AST::FunctionDeclaration(compiler->newStringRef(stringAt(binding->propertyNameIndex)), paramList, body); + functionDeclaration->functionToken = foe->node->firstSourceLocation(); foe->node = functionDeclaration; binding->propertyNameIndex = compiler->registerString(propertyName); |