From 01a1ad296c2b8325476abd6d28c8cc2463c42eb6 Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Tue, 8 May 2018 14:34:58 +0200 Subject: Support destructuring inside catch() Change-Id: Ib60b56ac6a7111446e01235564a4cf92ad8ad025 Reviewed-by: Simon Hausmann --- src/qml/parser/qqmljsast_p.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/qml/parser/qqmljsast_p.h') diff --git a/src/qml/parser/qqmljsast_p.h b/src/qml/parser/qqmljsast_p.h index e54d1aea31..36060f7358 100644 --- a/src/qml/parser/qqmljsast_p.h +++ b/src/qml/parser/qqmljsast_p.h @@ -2063,9 +2063,9 @@ class QML_PARSER_EXPORT Catch: public Node public: QQMLJS_DECLARE_AST_NODE(Catch) - Catch(const QStringRef &n, Block *stmt): - name (n), statement (stmt) - { kind = K; } + Catch(PatternElement *p, Block *stmt) + : patternElement(p), statement(stmt) + { kind = K; } void accept0(Visitor *visitor) override; @@ -2076,7 +2076,7 @@ public: { return statement->lastSourceLocation(); } // attributes - QStringRef name; + PatternElement *patternElement; Block *statement; SourceLocation catchToken; SourceLocation lparenToken; -- cgit v1.2.3