| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/isolate.h" | 5 #include "vm/isolate.h" |
| 6 | 6 |
| 7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 #include "platform/json.h" | 9 #include "platform/json.h" |
| 10 #include "lib/mirrors.h" | 10 #include "lib/mirrors.h" |
| (...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 727 | 727 |
| 728 | 728 |
| 729 class FinalizeWeakPersistentHandlesVisitor : public HandleVisitor { | 729 class FinalizeWeakPersistentHandlesVisitor : public HandleVisitor { |
| 730 public: | 730 public: |
| 731 FinalizeWeakPersistentHandlesVisitor() : HandleVisitor(Isolate::Current()) { | 731 FinalizeWeakPersistentHandlesVisitor() : HandleVisitor(Isolate::Current()) { |
| 732 } | 732 } |
| 733 | 733 |
| 734 void VisitHandle(uword addr, bool is_prologue_weak) { | 734 void VisitHandle(uword addr, bool is_prologue_weak) { |
| 735 FinalizablePersistentHandle* handle = | 735 FinalizablePersistentHandle* handle = |
| 736 reinterpret_cast<FinalizablePersistentHandle*>(addr); | 736 reinterpret_cast<FinalizablePersistentHandle*>(addr); |
| 737 FinalizablePersistentHandle::Finalize(isolate(), handle, is_prologue_weak); | 737 handle->UpdateUnreachable(isolate(), is_prologue_weak); |
| 738 } | 738 } |
| 739 | 739 |
| 740 private: | 740 private: |
| 741 DISALLOW_COPY_AND_ASSIGN(FinalizeWeakPersistentHandlesVisitor); | 741 DISALLOW_COPY_AND_ASSIGN(FinalizeWeakPersistentHandlesVisitor); |
| 742 }; | 742 }; |
| 743 | 743 |
| 744 | 744 |
| 745 void Isolate::Shutdown() { | 745 void Isolate::Shutdown() { |
| 746 ASSERT(this == Isolate::Current()); | 746 ASSERT(this == Isolate::Current()); |
| 747 ASSERT(top_resource() == NULL); | 747 ASSERT(top_resource() == NULL); |
| (...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1078 return func.raw(); | 1078 return func.raw(); |
| 1079 } | 1079 } |
| 1080 | 1080 |
| 1081 | 1081 |
| 1082 void IsolateSpawnState::Cleanup() { | 1082 void IsolateSpawnState::Cleanup() { |
| 1083 SwitchIsolateScope switch_scope(isolate()); | 1083 SwitchIsolateScope switch_scope(isolate()); |
| 1084 Dart::ShutdownIsolate(); | 1084 Dart::ShutdownIsolate(); |
| 1085 } | 1085 } |
| 1086 | 1086 |
| 1087 } // namespace dart | 1087 } // namespace dart |
| OLD | NEW |