Index: test/cctest/test-alloc.cc |
diff --git a/test/cctest/test-alloc.cc b/test/cctest/test-alloc.cc |
index 2936d6e7e12fdb0577ce627c048b5ce211953509..fcf2ce4f1b870e424df8e7762bee6d59eab6c6fb 100644 |
--- a/test/cctest/test-alloc.cc |
+++ b/test/cctest/test-alloc.cc |
@@ -35,7 +35,7 @@ |
using namespace v8::internal; |
-static Object* AllocateAfterFailures() { |
+static MaybeObject* AllocateAfterFailures() { |
static int attempts = 0; |
if (++attempts < 3) return Failure::RetryAfterGC(); |
@@ -60,7 +60,8 @@ static Object* AllocateAfterFailures() { |
CHECK(!Heap::AllocateFixedArray(100)->IsFailure()); |
CHECK(!Heap::AllocateHeapNumber(0.42)->IsFailure()); |
CHECK(!Heap::AllocateArgumentsObject(Smi::FromInt(87), 10)->IsFailure()); |
- Object* object = Heap::AllocateJSObject(*Top::object_function()); |
+ Object* object = |
+ Heap::AllocateJSObject(*Top::object_function())->ToObjectChecked(); |
CHECK(!Heap::CopyJSObject(JSObject::cast(object))->IsFailure()); |
// Old data space. |
@@ -111,7 +112,7 @@ TEST(StressHandles) { |
} |
-static Object* TestAccessorGet(Object* object, void*) { |
+static MaybeObject* TestAccessorGet(Object* object, void*) { |
return AllocateAfterFailures(); |
} |