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(); |