Index: test/cctest/test-assembler-arm64.cc |
diff --git a/test/cctest/test-assembler-arm64.cc b/test/cctest/test-assembler-arm64.cc |
index 3264352175843916755e53bab8f1cca8c38e6b70..a97e575e11149ab3fbc68719159763204472170f 100644 |
--- a/test/cctest/test-assembler-arm64.cc |
+++ b/test/cctest/test-assembler-arm64.cc |
@@ -10937,19 +10937,15 @@ TEST(pool_size) { |
__ bind(&exit); |
- Heap* heap = isolate->heap(); |
+ HandleScope handle_scope(isolate); |
CodeDesc desc; |
- Object* code_object = NULL; |
- Code* code; |
masm.GetCode(&desc); |
- MaybeObject* maybe_code = heap->CreateCode(desc, 0, masm.CodeObject()); |
- maybe_code->ToObject(&code_object); |
- code = Code::cast(code_object); |
+ Handle<Code> code = isolate->factory()->NewCode(desc, 0, masm.CodeObject()); |
unsigned pool_count = 0; |
int pool_mask = RelocInfo::ModeMask(RelocInfo::CONST_POOL) | |
RelocInfo::ModeMask(RelocInfo::VENEER_POOL); |
- for (RelocIterator it(code, pool_mask); !it.done(); it.next()) { |
+ for (RelocIterator it(*code, pool_mask); !it.done(); it.next()) { |
RelocInfo* info = it.rinfo(); |
if (RelocInfo::IsConstPool(info->rmode())) { |
ASSERT(info->data() == constant_pool_size); |