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

Unified Diff: src/isolate.cc

Issue 2417743004: Add option to print all exceptions (Closed)
Patch Set: Created 4 years, 2 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 | « src/flag-definitions.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/isolate.cc
diff --git a/src/isolate.cc b/src/isolate.cc
index a15b1cf345ee00f6740e7e412aee7a745359ffa1..4dc70bff4c0a37f0f04ac7db0d62ecc9cb4c7b14 100644
--- a/src/isolate.cc
+++ b/src/isolate.cc
@@ -1070,6 +1070,15 @@ Object* Isolate::Throw(Object* exception, MessageLocation* location) {
HandleScope scope(this);
Handle<Object> exception_handle(exception, this);
+ if (FLAG_print_all_exceptions) {
+ printf("=========================================================\n");
+ printf("Exception thrown:\n");
+ exception->Print();
+ printf("Stack Trace:\n");
+ PrintStack(stdout);
+ printf("=========================================================\n");
+ }
+
// Determine whether a message needs to be created for the given exception
// depending on the following criteria:
// 1) External v8::TryCatch missing: Always create a message because any
« no previous file with comments | « src/flag-definitions.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698