aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4scopedvalue_p.h
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2017-01-05 22:21:35 +0100
committerLars Knoll <lars.knoll@qt.io>2017-01-25 08:31:28 +0000
commit25552c1404dff66ae9681e57f2b9a8be08d3828a (patch)
treef0f00a1e53d1eedc0ee93f32243555a4d43eeeaa /src/qml/jsruntime/qv4scopedvalue_p.h
parent381e3151aea83806fb5bea2407fef67de3cc5014 (diff)
Convert more builtin functions to the new calling convention
Change-Id: I053215261e1186aff25f29e0967219ef667f7678 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4scopedvalue_p.h')
-rw-r--r--src/qml/jsruntime/qv4scopedvalue_p.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/qml/jsruntime/qv4scopedvalue_p.h b/src/qml/jsruntime/qv4scopedvalue_p.h
index 6cdc6200e7..6775028272 100644
--- a/src/qml/jsruntime/qv4scopedvalue_p.h
+++ b/src/qml/jsruntime/qv4scopedvalue_p.h
@@ -94,6 +94,12 @@ struct ScopedValue;
return; \
} while (false)
+#define THROW_GENERIC_ERROR(str) \
+ do { \
+ scope.result = scope.engine->throwError(QString::fromUtf8(str)); \
+ return; \
+ } while (false)
+
struct Scope {
inline Scope(ExecutionContext *ctx)
: engine(ctx->d()->engine)