Revert r11834 because of broken Chromium unit test.
authormstarzinger@chromium.org <mstarzinger@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 21 Jun 2012 11:10:53 +0000 (11:10 +0000)
committermstarzinger@chromium.org <mstarzinger@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 21 Jun 2012 11:10:53 +0000 (11:10 +0000)
R=yangguo@chromium.org
BUG=v8:2166

Review URL: https://chromiumcodereview.appspot.com/10630003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@11892 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

src/isolate.cc
test/cctest/test-api.cc

index 61e43b1..30c60b6 100644 (file)
@@ -945,12 +945,9 @@ void Isolate::ScheduleThrow(Object* exception) {
   // When scheduling a throw we first throw the exception to get the
   // error reporting if it is uncaught before rescheduling it.
   Throw(exception);
-  PropagatePendingExceptionToExternalTryCatch();
-  if (has_pending_exception()) {
-    thread_local_top()->scheduled_exception_ = pending_exception();
-    thread_local_top()->external_caught_exception_ = false;
-    clear_pending_exception();
-  }
+  thread_local_top()->scheduled_exception_ = pending_exception();
+  thread_local_top()->external_caught_exception_ = false;
+  clear_pending_exception();
 }
 
 
index 759d168..2296072 100644 (file)
@@ -3363,30 +3363,6 @@ THREADED_TEST(TryCatchAndFinally) {
 }
 
 
-static void TryCatchNestedHelper(int depth) {
-  if (depth > 0) {
-    v8::TryCatch try_catch;
-    try_catch.SetVerbose(true);
-    TryCatchNestedHelper(depth - 1);
-    CHECK(try_catch.HasCaught());
-    try_catch.ReThrow();
-  } else {
-    v8::ThrowException(v8_str("back"));
-  }
-}
-
-
-TEST(TryCatchNested) {
-  v8::V8::Initialize();
-  v8::HandleScope scope;
-  LocalContext context;
-  v8::TryCatch try_catch;
-  TryCatchNestedHelper(5);
-  CHECK(try_catch.HasCaught());
-  CHECK_EQ(0, strcmp(*v8::String::Utf8Value(try_catch.Exception()), "back"));
-}
-
-
 THREADED_TEST(Equality) {
   v8::HandleScope scope;
   LocalContext context;