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

Unified Diff: src/isolate.h

Issue 15669003: Fix TryCatch.ReThrow() to not clobber Message. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 7 years, 7 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/api.cc ('k') | src/isolate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/isolate.h
===================================================================
--- src/isolate.h (revision 14909)
+++ src/isolate.h (working copy)
@@ -245,6 +245,7 @@
ThreadId thread_id_;
MaybeObject* pending_exception_;
bool has_pending_message_;
+ bool restoring_message_;
Object* pending_message_obj_;
Script* pending_message_script_;
int pending_message_start_pos_;
@@ -582,6 +583,7 @@
}
void clear_pending_message() {
thread_local_top_.has_pending_message_ = false;
+ thread_local_top_.restoring_message_ = false;
thread_local_top_.pending_message_obj_ = heap_.the_hole_value();
thread_local_top_.pending_message_script_ = NULL;
}
@@ -761,6 +763,9 @@
// originally.
Failure* ReThrow(MaybeObject* exception);
void ScheduleThrow(Object* exception);
+ void RestoreMessage(Object* message, Script* script, int start, int end);
+ // Re-set message, script, position saved in TryCatch to the TLS
+ // so that ReThrow() does not overwrite them with a new message.
void ReportPendingMessages();
// Return pending location if any or unfilled structure.
MessageLocation GetMessageLocation();
« no previous file with comments | « src/api.cc ('k') | src/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698