aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4compilercontext_p.h
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2017-08-31 15:35:20 +0200
committerLars Knoll <lars.knoll@qt.io>2017-09-02 07:12:22 +0000
commit020ad3d259f57c379fbcdd4e69c235dd1b0a3774 (patch)
tree170e5199a8b7327ca7f46eccf557e5803224c488 /src/qml/compiler/qv4compilercontext_p.h
parent74c8fe86755af485f8d0a47799d6d50f00070f05 (diff)
Get rid of the hack for named expressions
Instead simply use the pointer to the FunctionObject we have in the CallData now. Change-Id: I6d7ed8af22e89e0217bef427110611b661ac7965 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/compiler/qv4compilercontext_p.h')
-rw-r--r--src/qml/compiler/qv4compilercontext_p.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/compiler/qv4compilercontext_p.h b/src/qml/compiler/qv4compilercontext_p.h
index b796a5f149..f35125e719 100644
--- a/src/qml/compiler/qv4compilercontext_p.h
+++ b/src/qml/compiler/qv4compilercontext_p.h
@@ -109,6 +109,7 @@ struct Context {
enum MemberType {
UndefinedMember,
+ ThisFunctionName,
VariableDefinition,
VariableDeclaration,
FunctionDefinition
@@ -140,7 +141,6 @@ struct Context {
bool hasDirectEval = false;
bool hasNestedFunctions = false;
bool isStrict = false;
- bool isNamedFunctionExpression = false;
bool usesThis = false;
bool hasTry = false;
bool hasWith = false;
@@ -217,7 +217,7 @@ struct Context {
bool canUseSimpleCall() const {
return nestedContexts.isEmpty() &&
locals.isEmpty() && arguments.size() <= QV4::Global::ReservedArgumentCount &&
- !hasTry && !hasWith && !isNamedFunctionExpression &&
+ !hasTry && !hasWith &&
usesArgumentsObject == ArgumentsObjectNotUsed && !hasDirectEval;
}