| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 | 8 |
| 9 #include "vm/assert.h" | 9 #include "vm/assert.h" |
| 10 #include "vm/bigint_store.h" | 10 #include "vm/bigint_store.h" |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 if (FLAG_generate_gdb_symbols) { | 223 if (FLAG_generate_gdb_symbols) { |
| 224 DebugInfo::UnregisterAllSections(); | 224 DebugInfo::UnregisterAllSections(); |
| 225 } | 225 } |
| 226 | 226 |
| 227 // TODO(5411455): For now just make sure there are no current isolates | 227 // TODO(5411455): For now just make sure there are no current isolates |
| 228 // as we are shutting down the isolate. | 228 // as we are shutting down the isolate. |
| 229 SetCurrent(NULL); | 229 SetCurrent(NULL); |
| 230 } | 230 } |
| 231 | 231 |
| 232 | 232 |
| 233 Dart_IsolateInitCallback Isolate::init_callback_ = NULL; | 233 Dart_IsolateCreateCallback Isolate::create_callback_ = NULL; |
| 234 | 234 |
| 235 | 235 |
| 236 void Isolate::SetInitCallback(Dart_IsolateInitCallback callback) { | 236 void Isolate::SetCreateCallback(Dart_IsolateCreateCallback cb) { |
| 237 init_callback_ = callback; | 237 create_callback_ = cb; |
| 238 } | 238 } |
| 239 | 239 |
| 240 | 240 |
| 241 Dart_IsolateInitCallback Isolate::InitCallback() { | 241 Dart_IsolateCreateCallback Isolate::CreateCallback() { |
| 242 return init_callback_; | 242 return create_callback_; |
| 243 } | 243 } |
| 244 | 244 |
| 245 | 245 |
| 246 void Isolate::StandardRunLoop() { | 246 void Isolate::StandardRunLoop() { |
| 247 ASSERT(long_jump_base() != NULL); | 247 ASSERT(long_jump_base() != NULL); |
| 248 ASSERT(post_message_callback() == &StandardPostMessageCallback); | 248 ASSERT(post_message_callback() == &StandardPostMessageCallback); |
| 249 ASSERT(close_port_callback() == &StandardClosePortCallback); | 249 ASSERT(close_port_callback() == &StandardClosePortCallback); |
| 250 | 250 |
| 251 while (live_ports() > 0) { | 251 while (live_ports() > 0) { |
| 252 ASSERT(this == Isolate::Current()); | 252 ASSERT(this == Isolate::Current()); |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 305 } | 305 } |
| 306 | 306 |
| 307 // Visit the top context which is stored in the isolate. | 307 // Visit the top context which is stored in the isolate. |
| 308 visitor->VisitPointer(reinterpret_cast<RawObject**>(&top_context_)); | 308 visitor->VisitPointer(reinterpret_cast<RawObject**>(&top_context_)); |
| 309 | 309 |
| 310 // Visit objects in the debugger. | 310 // Visit objects in the debugger. |
| 311 debugger()->VisitObjectPointers(visitor); | 311 debugger()->VisitObjectPointers(visitor); |
| 312 } | 312 } |
| 313 | 313 |
| 314 } // namespace dart | 314 } // namespace dart |
| OLD | NEW |