Index: test/cctest/test-compiler.cc |
diff --git a/test/cctest/test-compiler.cc b/test/cctest/test-compiler.cc |
index 96549a37e7fa06a91942cc39119fd2490c2978db..b424b7f9e1483571ac7c6f9abd76572c50d1c390 100644 |
--- a/test/cctest/test-compiler.cc |
+++ b/test/cctest/test-compiler.cc |
@@ -98,7 +98,7 @@ static void InitializeVM() { |
} |
-static Object* GetGlobalProperty(const char* name) { |
+static MaybeObject* GetGlobalProperty(const char* name) { |
Handle<String> symbol = Factory::LookupAsciiSymbol(name); |
return Top::context()->global()->GetProperty(*symbol); |
} |
@@ -140,7 +140,7 @@ static double Inc(int x) { |
Handle<JSObject> global(Top::context()->global()); |
Execution::Call(fun, global, 0, NULL, &has_pending_exception); |
CHECK(!has_pending_exception); |
- return GetGlobalProperty("result")->Number(); |
+ return GetGlobalProperty("result")->ToObjectChecked()->Number(); |
} |
@@ -161,7 +161,7 @@ static double Add(int x, int y) { |
Handle<JSObject> global(Top::context()->global()); |
Execution::Call(fun, global, 0, NULL, &has_pending_exception); |
CHECK(!has_pending_exception); |
- return GetGlobalProperty("result")->Number(); |
+ return GetGlobalProperty("result")->ToObjectChecked()->Number(); |
} |
@@ -181,7 +181,7 @@ static double Abs(int x) { |
Handle<JSObject> global(Top::context()->global()); |
Execution::Call(fun, global, 0, NULL, &has_pending_exception); |
CHECK(!has_pending_exception); |
- return GetGlobalProperty("result")->Number(); |
+ return GetGlobalProperty("result")->ToObjectChecked()->Number(); |
} |
@@ -202,7 +202,7 @@ static double Sum(int n) { |
Handle<JSObject> global(Top::context()->global()); |
Execution::Call(fun, global, 0, NULL, &has_pending_exception); |
CHECK(!has_pending_exception); |
- return GetGlobalProperty("result")->Number(); |
+ return GetGlobalProperty("result")->ToObjectChecked()->Number(); |
} |
@@ -256,7 +256,7 @@ TEST(Stuff) { |
Handle<JSObject> global(Top::context()->global()); |
Execution::Call(fun, global, 0, NULL, &has_pending_exception); |
CHECK(!has_pending_exception); |
- CHECK_EQ(511.0, GetGlobalProperty("r")->Number()); |
+ CHECK_EQ(511.0, GetGlobalProperty("r")->ToObjectChecked()->Number()); |
} |
@@ -272,7 +272,7 @@ TEST(UncaughtThrow) { |
Handle<Object> result = |
Execution::Call(fun, global, 0, NULL, &has_pending_exception); |
CHECK(has_pending_exception); |
- CHECK_EQ(42.0, Top::pending_exception()->Number()); |
+ CHECK_EQ(42.0, Top::pending_exception()->ToObjectChecked()->Number()); |
} |
@@ -297,10 +297,10 @@ TEST(C2JSFrames) { |
Execution::Call(fun0, global, 0, NULL, &has_pending_exception); |
CHECK(!has_pending_exception); |
- Handle<Object> fun1 = |
- Handle<Object>( |
- Top::context()->global()->GetProperty( |
- *Factory::LookupAsciiSymbol("foo"))); |
+ Object* foo_symbol = Factory::LookupAsciiSymbol("foo")->ToObjectChecked(); |
+ MaybeObject* fun1_object = |
+ Top::context()->global()->GetProperty(String::cast(foo_symbol)); |
+ Handle<Object> fun1(fun1_object->ToObjectChecked()); |
CHECK(fun1->IsJSFunction()); |
Object** argv[1] = { |