Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Unified Diff: include/v8.h

Issue 203223013: Introduce API to trigger exception on JS execution. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: addressed comment Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8.h
diff --git a/include/v8.h b/include/v8.h
index 942ef4d95f86c88115e3a67673a8bf853442cc30..4ff5830115c2b8737a679b368fa97497808b7c2f 100644
--- a/include/v8.h
+++ b/include/v8.h
@@ -4090,10 +4090,14 @@ class V8_EXPORT Isolate {
*/
class DisallowJavascriptExecutionScope {
public:
- explicit DisallowJavascriptExecutionScope(Isolate* isolate);
+ enum OnFailure { CRASH_ON_FAILURE, THROW_ON_FAILURE };
+
+ explicit DisallowJavascriptExecutionScope(Isolate* isolate,
tfarina 2014/03/19 19:14:16 remove explicit? not needed anymore, right?
+ OnFailure on_failure);
~DisallowJavascriptExecutionScope();
private:
+ bool on_failure_;
void* internal_;
// Prevent copying of Scope objects.
@@ -4112,7 +4116,13 @@ class V8_EXPORT Isolate {
~AllowJavascriptExecutionScope();
private:
- void* internal_;
+ void* internal_throws_;
+ void* internal_assert_;
+
+ // Prevent copying of Scope objects.
+ AllowJavascriptExecutionScope(const AllowJavascriptExecutionScope&);
+ AllowJavascriptExecutionScope& operator=(
+ const AllowJavascriptExecutionScope&);
};
/**
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698