Index: runtime/vm/isolate.cc |
=================================================================== |
--- runtime/vm/isolate.cc (revision 8116) |
+++ runtime/vm/isolate.cc (working copy) |
@@ -46,6 +46,8 @@ |
// Check that it is safe to access this handler. |
void CheckAccess(); |
#endif |
+ bool IsCurrentIsolate() const; |
+ |
private: |
Isolate* isolate_; |
}; |
@@ -120,11 +122,16 @@ |
#if defined(DEBUG) |
void IsolateMessageHandler::CheckAccess() { |
- ASSERT(isolate_ == Isolate::Current()); |
+ ASSERT(IsCurrentIsolate()); |
} |
#endif |
+bool IsolateMessageHandler::IsCurrentIsolate() const { |
+ return (isolate_ == Isolate::Current()); |
+} |
+ |
+ |
#if defined(DEBUG) |
// static |
void BaseIsolate::AssertCurrent(BaseIsolate* isolate) { |