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/service.h" | 5 #include "vm/service.h" |
6 | 6 |
7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
8 #include "platform/globals.h" | 8 #include "platform/globals.h" |
9 | 9 |
10 #include "vm/compiler.h" | 10 #include "vm/compiler.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 #include "vm/service_isolate.h" | 31 #include "vm/service_isolate.h" |
32 #include "vm/stack_frame.h" | 32 #include "vm/stack_frame.h" |
33 #include "vm/symbols.h" | 33 #include "vm/symbols.h" |
34 #include "vm/unicode.h" | 34 #include "vm/unicode.h" |
35 #include "vm/version.h" | 35 #include "vm/version.h" |
36 | 36 |
37 namespace dart { | 37 namespace dart { |
38 | 38 |
39 DECLARE_FLAG(bool, trace_service); | 39 DECLARE_FLAG(bool, trace_service); |
40 DECLARE_FLAG(bool, trace_service_pause_events); | 40 DECLARE_FLAG(bool, trace_service_pause_events); |
41 DECLARE_FLAG(bool, enable_type_checks); | |
42 DECLARE_FLAG(bool, enable_asserts); | |
43 | 41 |
44 // TODO(johnmccutchan): Unify embedder service handler lists and their APIs. | 42 // TODO(johnmccutchan): Unify embedder service handler lists and their APIs. |
45 EmbedderServiceHandler* Service::isolate_service_handler_head_ = NULL; | 43 EmbedderServiceHandler* Service::isolate_service_handler_head_ = NULL; |
46 EmbedderServiceHandler* Service::root_service_handler_head_ = NULL; | 44 EmbedderServiceHandler* Service::root_service_handler_head_ = NULL; |
47 struct ServiceMethodDescriptor; | 45 struct ServiceMethodDescriptor; |
48 ServiceMethodDescriptor* FindMethod(const char* method_name); | 46 ServiceMethodDescriptor* FindMethod(const char* method_name); |
49 | 47 |
50 static uint8_t* allocator(uint8_t* ptr, intptr_t old_size, intptr_t new_size) { | 48 static uint8_t* allocator(uint8_t* ptr, intptr_t old_size, intptr_t new_size) { |
51 void* new_ptr = realloc(reinterpret_cast<void*>(ptr), new_size); | 49 void* new_ptr = realloc(reinterpret_cast<void*>(ptr), new_size); |
52 return reinterpret_cast<uint8_t*>(new_ptr); | 50 return reinterpret_cast<uint8_t*>(new_ptr); |
(...skipping 2573 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2626 ServiceMethodDescriptor& method = service_methods_[i]; | 2624 ServiceMethodDescriptor& method = service_methods_[i]; |
2627 if (strcmp(method_name, method.name) == 0) { | 2625 if (strcmp(method_name, method.name) == 0) { |
2628 return &method; | 2626 return &method; |
2629 } | 2627 } |
2630 } | 2628 } |
2631 return NULL; | 2629 return NULL; |
2632 } | 2630 } |
2633 | 2631 |
2634 | 2632 |
2635 } // namespace dart | 2633 } // namespace dart |
OLD | NEW |