| Index: test/cctest/test-api.cc
|
| diff --git a/test/cctest/test-api.cc b/test/cctest/test-api.cc
|
| index bc9a0e2ca2fa56d00025e6a68a4af27f754ee2ff..2b8b57f85e4a336a4dc0b5b8ff05700e9fb7e740 100644
|
| --- a/test/cctest/test-api.cc
|
| +++ b/test/cctest/test-api.cc
|
| @@ -10620,17 +10620,16 @@ TEST(PreCompileInvalidPreparseDataError) {
|
| *exception_value);
|
|
|
| try_catch.Reset();
|
| +
|
| // Overwrite function bar's start position with 200. The function entry
|
| - // will not be found when searching for it by position.
|
| + // will not be found when searching for it by position and we should fall
|
| + // back on eager compilation.
|
| sd = v8::ScriptData::PreCompile(script, i::StrLength(script));
|
| sd_data = reinterpret_cast<unsigned*>(const_cast<char*>(sd->Data()));
|
| sd_data[kHeaderSize + 1 * kFunctionEntrySize + kFunctionEntryStartOffset] =
|
| 200;
|
| compiled_script = Script::New(source, NULL, sd);
|
| - CHECK(try_catch.HasCaught());
|
| - String::AsciiValue second_exception_value(try_catch.Message()->Get());
|
| - CHECK_EQ("Uncaught SyntaxError: Invalid preparser data for function bar",
|
| - *second_exception_value);
|
| + CHECK(!try_catch.HasCaught());
|
|
|
| delete sd;
|
| }
|
|
|