summaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4engine_p.h
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2018-05-14 14:12:33 +0200
committerLars Knoll <lars.knoll@qt.io>2018-05-14 19:32:42 +0000
commitc4ef0d6e4b5bb7de7b0ab08928d693988a60b25d (patch)
tree0ff9682886da081c2d8e89becfd90cfb7083540d /src/qml/jsruntime/qv4engine_p.h
parentd8eade23bc4fdd7040204f4374ef26975b94ea0a (diff)
Call iterator.return when required in destructuring assignments
Array destructuring assignments require a call to iterator.return if the iterator hasn't been exhausted during destructuring. Change-Id: I39fe4bc01bef6fb2ad3bda92caf6779fbbddc8e2 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4engine_p.h')
-rw-r--r--src/qml/jsruntime/qv4engine_p.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qml/jsruntime/qv4engine_p.h b/src/qml/jsruntime/qv4engine_p.h
index 46bf58de07..e90be8e896 100644
--- a/src/qml/jsruntime/qv4engine_p.h
+++ b/src/qml/jsruntime/qv4engine_p.h
@@ -329,6 +329,7 @@ public:
String_lastIndex,
String_next,
String_done,
+ String_return,
NJSStrings
};
@@ -389,6 +390,7 @@ public:
String *id_lastIndex() const { return reinterpret_cast<String *>(jsStrings + String_lastIndex); }
String *id_next() const { return reinterpret_cast<String *>(jsStrings + String_next); }
String *id_done() const { return reinterpret_cast<String *>(jsStrings + String_done); }
+ String *id_return() const { return reinterpret_cast<String *>(jsStrings + String_return); }
Symbol *symbol_hasInstance() const { return reinterpret_cast<Symbol *>(jsSymbols + Symbol_hasInstance); }
Symbol *symbol_isConcatSpreadable() const { return reinterpret_cast<Symbol *>(jsSymbols + Symbol_isConcatSpreadable); }