Index: runtime/vm/dart_api_impl.cc |
=================================================================== |
--- runtime/vm/dart_api_impl.cc (revision 33332) |
+++ runtime/vm/dart_api_impl.cc (working copy) |
@@ -614,8 +614,8 @@ |
Dart_WeakPersistentHandleFinalizer callback) { |
ApiState* state = isolate->api_state(); |
ASSERT(state != NULL); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& ref = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& ref = isolate->ObjectHandle(); |
ref = Api::UnwrapHandle(object); |
FinalizablePersistentHandle* finalizable_ref = is_prologue ? |
state->prologue_weak_persistent_handles().AllocateHandle() : |
@@ -1375,8 +1375,8 @@ |
DART_EXPORT bool Dart_IsInstance(Dart_Handle object) { |
Isolate* isolate = Isolate::Current(); |
CHECK_ISOLATE(isolate); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& ref = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& ref = isolate->ObjectHandle(); |
ref = Api::UnwrapHandle(object); |
return ref.IsInstance(); |
} |
@@ -3883,8 +3883,8 @@ |
} |
Isolate* isolate = arguments->isolate(); |
CHECK_ISOLATE(isolate); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& obj = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& obj = isolate->ObjectHandle(); |
obj = arguments->NativeArgAt(arg_index); |
if (obj.IsNull()) { |
for (intptr_t i = 0; i < num_fields; i++) { |
@@ -3934,8 +3934,8 @@ |
return Api::Success(); |
} |
*peer = NULL; |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& obj = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& obj = isolate->ObjectHandle(); |
obj = arguments->NativeArgAt(arg_index); |
if (RawObject::IsStringClassId(obj.GetClassId())) { |
return Api::NewHandle(isolate, obj.raw()); |
@@ -3959,8 +3959,8 @@ |
CURRENT_FUNC, arguments->NativeArgCount() - 1, index); |
} |
Isolate* isolate = arguments->isolate(); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& obj = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& obj = isolate->ObjectHandle(); |
obj = arguments->NativeArgAt(index); |
intptr_t cid = obj.GetClassId(); |
if (cid == kSmiCid) { |
@@ -4016,8 +4016,8 @@ |
CURRENT_FUNC, arguments->NativeArgCount() - 1, index); |
} |
Isolate* isolate = arguments->isolate(); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& obj = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& obj = isolate->ObjectHandle(); |
obj = arguments->NativeArgAt(index); |
intptr_t cid = obj.GetClassId(); |
if (cid == kDoubleCid) { |
@@ -4555,8 +4555,8 @@ |
} |
Isolate* isolate = Isolate::Current(); |
CHECK_ISOLATE(isolate); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& obj = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& obj = isolate->ObjectHandle(); |
obj = Api::UnwrapHandle(object); |
if (obj.IsNull() || obj.IsNumber() || obj.IsBool()) { |
const char* msg = |
@@ -4575,8 +4575,8 @@ |
DART_EXPORT Dart_Handle Dart_SetPeer(Dart_Handle object, void* peer) { |
Isolate* isolate = Isolate::Current(); |
CHECK_ISOLATE(isolate); |
- ReusableObjectHandleScope reused_obj_handle(isolate); |
- Object& obj = reused_obj_handle.Handle(); |
+ REUSABLE_OBJECT_HANDLESCOPE(isolate); |
+ Object& obj = isolate->ObjectHandle(); |
obj = Api::UnwrapHandle(object); |
if (obj.IsNull() || obj.IsNumber() || obj.IsBool()) { |
const char* msg = |