Index: runtime/vm/isolate.cc |
=================================================================== |
--- runtime/vm/isolate.cc (revision 33332) |
+++ runtime/vm/isolate.cc (working copy) |
@@ -273,8 +273,14 @@ |
void BaseIsolate::AssertCurrent(BaseIsolate* isolate) { |
ASSERT(isolate == Isolate::Current()); |
} |
-#endif |
+#endif // defined(DEBUG) |
+#if defined(DEBUG) |
+#define REUSABLE_HANDLE_SCOPE_INIT(object) \ |
+ reusable_##object##_handle_scope_active_(false), |
+#else |
+#define REUSABLE_HANDLE_SCOPE_INIT(object) |
+#endif // defined(DEBUG) |
#define REUSABLE_HANDLE_INITIALIZERS(object) \ |
object##_handle_(NULL), |
@@ -321,11 +327,13 @@ |
thread_state_(NULL), |
next_(NULL), |
REUSABLE_HANDLE_LIST(REUSABLE_HANDLE_INITIALIZERS) |
+ REUSABLE_HANDLE_LIST(REUSABLE_HANDLE_SCOPE_INIT) |
reusable_handles_() { |
if (FLAG_print_object_histogram && (Dart::vm_isolate() != NULL)) { |
object_histogram_ = new ObjectHistogram(this); |
} |
} |
+#undef REUSABLE_HANDLE_SCOPE_INIT |
#undef REUSABLE_HANDLE_INITIALIZERS |
@@ -402,8 +410,7 @@ |
// Setup the isolate specific resuable handles. |
#define REUSABLE_HANDLE_ALLOCATION(object) \ |
- result->object##_handle_ = result->AllocateReusableHandle<object>(); \ |
- |
+ result->object##_handle_ = result->AllocateReusableHandle<object>(); |
REUSABLE_HANDLE_LIST(REUSABLE_HANDLE_ALLOCATION) |
#undef REUSABLE_HANDLE_ALLOCATION |