Removed a few calls to Top::ReportPendingMessages() that caused the messages to be reported prematurely and not at the C++/JS boundary.
Review URL: http://codereview.chromium.org/13287 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@954 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
bbbab4821c
commit
90611c0ef7
@ -101,7 +101,6 @@ static Handle<JSFunction> MakeFunction(bool is_global,
|
|||||||
// Check for parse errors.
|
// Check for parse errors.
|
||||||
if (lit == NULL) {
|
if (lit == NULL) {
|
||||||
ASSERT(Top::has_pending_exception());
|
ASSERT(Top::has_pending_exception());
|
||||||
Top::ReportPendingMessages();
|
|
||||||
return Handle<JSFunction>::null();
|
return Handle<JSFunction>::null();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -119,7 +118,6 @@ static Handle<JSFunction> MakeFunction(bool is_global,
|
|||||||
// Check for stack-overflow exceptions.
|
// Check for stack-overflow exceptions.
|
||||||
if (code.is_null()) {
|
if (code.is_null()) {
|
||||||
Top::StackOverflow();
|
Top::StackOverflow();
|
||||||
Top::ReportPendingMessages();
|
|
||||||
return Handle<JSFunction>::null();
|
return Handle<JSFunction>::null();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -208,6 +206,8 @@ Handle<JSFunction> Compiler::Compile(Handle<String> source,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (result.is_null()) Top::ReportPendingMessages();
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -272,7 +272,6 @@ bool Compiler::CompileLazy(Handle<SharedFunctionInfo> shared,
|
|||||||
// Check for parse errors.
|
// Check for parse errors.
|
||||||
if (lit == NULL) {
|
if (lit == NULL) {
|
||||||
ASSERT(Top::has_pending_exception());
|
ASSERT(Top::has_pending_exception());
|
||||||
Top::ReportPendingMessages();
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -290,7 +289,6 @@ bool Compiler::CompileLazy(Handle<SharedFunctionInfo> shared,
|
|||||||
// Check for stack-overflow exception.
|
// Check for stack-overflow exception.
|
||||||
if (code.is_null()) {
|
if (code.is_null()) {
|
||||||
Top::StackOverflow();
|
Top::StackOverflow();
|
||||||
Top::ReportPendingMessages();
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1810,6 +1810,21 @@ v8::Handle<Value> JSCheck(const v8::Arguments& args) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
THREADED_TEST(EvalInTryFinally) {
|
||||||
|
v8::HandleScope scope;
|
||||||
|
LocalContext context;
|
||||||
|
v8::TryCatch try_catch;
|
||||||
|
CompileRun("(function() {"
|
||||||
|
" try {"
|
||||||
|
" eval('asldkf (*&^&*^');"
|
||||||
|
" } finally {"
|
||||||
|
" return;"
|
||||||
|
" }"
|
||||||
|
"})()");
|
||||||
|
CHECK(!try_catch.HasCaught());
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// This test works by making a stack of alternating JavaScript and C
|
// This test works by making a stack of alternating JavaScript and C
|
||||||
// activations. These activations set up exception handlers with regular
|
// activations. These activations set up exception handlers with regular
|
||||||
// intervals, one interval for C activations and another for JavaScript
|
// intervals, one interval for C activations and another for JavaScript
|
||||||
|
Loading…
Reference in New Issue
Block a user