Index: src/assert-scope.h |
diff --git a/src/assert-scope.h b/src/assert-scope.h |
index 4357056404ebf62a93d7beea8ca9baa7b77d98a6..428e6d007ef8d5a9a5d03ba9484b402a16674bec 100644 |
--- a/src/assert-scope.h |
+++ b/src/assert-scope.h |
@@ -49,6 +49,7 @@ enum PerThreadAssertType { |
enum PerIsolateAssertType { |
JAVASCRIPT_EXECUTION_ASSERT, |
+ JAVASCRIPT_EXECUTION_THROWS, |
ALLOCATION_FAILURE_ASSERT |
}; |
@@ -251,6 +252,14 @@ typedef PerIsolateAssertScope<JAVASCRIPT_EXECUTION_ASSERT, false> |
typedef PerIsolateAssertScope<JAVASCRIPT_EXECUTION_ASSERT, true> |
AllowJavascriptExecution; |
+// Scope in which javascript execution leads to exception being thrown. |
+typedef PerIsolateAssertScope<JAVASCRIPT_EXECUTION_THROWS, false> |
+ ThrowOnJavascriptExecution; |
+ |
+// Scope to introduce an exception to ThrowOnJavascriptExecution. |
+typedef PerIsolateAssertScope<JAVASCRIPT_EXECUTION_THROWS, true> |
+ NoThrowOnJavascriptExecution; |
+ |
// Scope to document where we do not expect an allocation failure. |
typedef PerIsolateAssertScopeDebugOnly<ALLOCATION_FAILURE_ASSERT, false> |
DisallowAllocationFailure; |