summaryrefslogtreecommitdiffstats
path: root/js/src/jsapi.h
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/jsapi.h')
-rw-r--r--js/src/jsapi.h24
1 files changed, 18 insertions, 6 deletions
diff --git a/js/src/jsapi.h b/js/src/jsapi.h
index 154c88f45..989abe47c 100644
--- a/js/src/jsapi.h
+++ b/js/src/jsapi.h
@@ -650,7 +650,8 @@ typedef enum JSExnType {
JSEXN_DEBUGGEEWOULDRUN,
JSEXN_WASMCOMPILEERROR,
JSEXN_WASMRUNTIMEERROR,
- JSEXN_WARN,
+ JSEXN_ERROR_LIMIT,
+ JSEXN_WARN = JSEXN_ERROR_LIMIT,
JSEXN_LIMIT
} JSExnType;
@@ -874,11 +875,7 @@ class MOZ_STACK_CLASS SourceBufferHolder final
#define JSFUN_CONSTRUCTOR 0x400 /* native that can be called as a ctor */
-// 0x800 /* Unused */
-
-#define JSFUN_HAS_REST 0x1000 /* function has ...rest parameter. */
-
-#define JSFUN_FLAGS_MASK 0x1e00 /* | of all the JSFUN_* flags */
+#define JSFUN_FLAGS_MASK 0x600 /* | of all the JSFUN_* flags */
/*
* If set, will allow redefining a non-configurable property, but only on a
@@ -6175,6 +6172,12 @@ class MOZ_STACK_CLASS JS_PUBLIC_API(ForOfIterator) {
bool next(JS::MutableHandleValue val, bool* done);
/**
+ * Close the iterator.
+ * For the case that completion type is throw.
+ */
+ void closeThrow();
+
+ /**
* If initialized with throwOnNonCallable = false, check whether
* the value is iterable.
*/
@@ -6627,5 +6630,14 @@ SetGetPerformanceGroupsCallback(JSContext*, GetGroupsCallback, void*);
} /* namespace js */
+namespace js {
+
+enum class CompletionKind {
+ Normal,
+ Return,
+ Throw
+};
+
+} /* namespace js */
#endif /* jsapi_h */