| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <stdlib.h> | 5 #include <stdlib.h> |
| 6 | 6 |
| 7 #include <fstream> // NOLINT(readability/streams) | 7 #include <fstream> // NOLINT(readability/streams) |
| 8 #include <sstream> | 8 #include <sstream> |
| 9 | 9 |
| 10 #include "src/v8.h" | 10 #include "src/v8.h" |
| (...skipping 2542 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2553 | 2553 |
| 2554 Handle<JSObject> Isolate::GetSymbolRegistry() { | 2554 Handle<JSObject> Isolate::GetSymbolRegistry() { |
| 2555 if (heap()->symbol_registry()->IsSmi()) { | 2555 if (heap()->symbol_registry()->IsSmi()) { |
| 2556 Handle<Map> map = factory()->NewMap(JS_OBJECT_TYPE, JSObject::kHeaderSize); | 2556 Handle<Map> map = factory()->NewMap(JS_OBJECT_TYPE, JSObject::kHeaderSize); |
| 2557 Handle<JSObject> registry = factory()->NewJSObjectFromMap(map); | 2557 Handle<JSObject> registry = factory()->NewJSObjectFromMap(map); |
| 2558 heap()->set_symbol_registry(*registry); | 2558 heap()->set_symbol_registry(*registry); |
| 2559 | 2559 |
| 2560 SetUpSubregistry(registry, map, "for"); | 2560 SetUpSubregistry(registry, map, "for"); |
| 2561 SetUpSubregistry(registry, map, "for_api"); | 2561 SetUpSubregistry(registry, map, "for_api"); |
| 2562 SetUpSubregistry(registry, map, "keyFor"); | 2562 SetUpSubregistry(registry, map, "keyFor"); |
| 2563 SetUpSubregistry(registry, map, "private_api"); | |
| 2564 heap()->AddPrivateGlobalSymbols( | |
| 2565 SetUpSubregistry(registry, map, "private_intern")); | |
| 2566 } | 2563 } |
| 2567 return Handle<JSObject>::cast(factory()->symbol_registry()); | 2564 return Handle<JSObject>::cast(factory()->symbol_registry()); |
| 2568 } | 2565 } |
| 2569 | 2566 |
| 2570 | 2567 |
| 2571 void Isolate::AddCallCompletedCallback(CallCompletedCallback callback) { | 2568 void Isolate::AddCallCompletedCallback(CallCompletedCallback callback) { |
| 2572 for (int i = 0; i < call_completed_callbacks_.length(); i++) { | 2569 for (int i = 0; i < call_completed_callbacks_.length(); i++) { |
| 2573 if (callback == call_completed_callbacks_.at(i)) return; | 2570 if (callback == call_completed_callbacks_.at(i)) return; |
| 2574 } | 2571 } |
| 2575 call_completed_callbacks_.Add(callback); | 2572 call_completed_callbacks_.Add(callback); |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2817 // Then check whether this scope intercepts. | 2814 // Then check whether this scope intercepts. |
| 2818 if ((flag & intercept_mask_)) { | 2815 if ((flag & intercept_mask_)) { |
| 2819 intercepted_flags_ |= flag; | 2816 intercepted_flags_ |= flag; |
| 2820 return true; | 2817 return true; |
| 2821 } | 2818 } |
| 2822 return false; | 2819 return false; |
| 2823 } | 2820 } |
| 2824 | 2821 |
| 2825 } // namespace internal | 2822 } // namespace internal |
| 2826 } // namespace v8 | 2823 } // namespace v8 |
| OLD | NEW |