OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 "src/bootstrapper.h" | 5 #include "src/bootstrapper.h" |
6 | 6 |
7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
8 #include "src/api-natives.h" | 8 #include "src/api-natives.h" |
9 #include "src/base/ieee754.h" | 9 #include "src/base/ieee754.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 1869 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1880 Handle<Map> prototype_map(prototype->map()); | 1880 Handle<Map> prototype_map(prototype->map()); |
1881 Map::SetShouldBeFastPrototypeMap(prototype_map, true, isolate); | 1881 Map::SetShouldBeFastPrototypeMap(prototype_map, true, isolate); |
1882 | 1882 |
1883 // Store the initial Promise.prototype map. This is used in fast-path | 1883 // Store the initial Promise.prototype map. This is used in fast-path |
1884 // checks. Do not alter the prototype after this point. | 1884 // checks. Do not alter the prototype after this point. |
1885 native_context()->set_promise_prototype_map(*prototype_map); | 1885 native_context()->set_promise_prototype_map(*prototype_map); |
1886 | 1886 |
1887 { // Internal: PromiseInternalConstructor | 1887 { // Internal: PromiseInternalConstructor |
1888 Handle<JSFunction> function = | 1888 Handle<JSFunction> function = |
1889 SimpleCreateFunction(isolate, factory->empty_string(), | 1889 SimpleCreateFunction(isolate, factory->empty_string(), |
1890 Builtins::kPromiseInternalConstructor, 0, false); | 1890 Builtins::kPromiseInternalConstructor, 1, false); |
1891 InstallWithIntrinsicDefaultProto( | 1891 InstallWithIntrinsicDefaultProto( |
1892 isolate, function, Context::PROMISE_INTERNAL_CONSTRUCTOR_INDEX); | 1892 isolate, function, Context::PROMISE_INTERNAL_CONSTRUCTOR_INDEX); |
1893 } | 1893 } |
1894 | 1894 |
1895 { // Internal: PromiseCreateAndSet | 1895 { // Internal: PromiseCreateAndSet |
1896 Handle<JSFunction> function = | 1896 Handle<JSFunction> function = |
1897 SimpleCreateFunction(isolate, factory->empty_string(), | 1897 SimpleCreateFunction(isolate, factory->empty_string(), |
1898 Builtins::kPromiseCreateAndSet, 2, false); | 1898 Builtins::kPromiseCreateAndSet, 2, false); |
1899 InstallWithIntrinsicDefaultProto(isolate, function, | 1899 InstallWithIntrinsicDefaultProto(isolate, function, |
1900 Context::PROMISE_CREATE_AND_SET_INDEX); | 1900 Context::PROMISE_CREATE_AND_SET_INDEX); |
(...skipping 2783 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4684 } | 4684 } |
4685 | 4685 |
4686 | 4686 |
4687 // Called when the top-level V8 mutex is destroyed. | 4687 // Called when the top-level V8 mutex is destroyed. |
4688 void Bootstrapper::FreeThreadResources() { | 4688 void Bootstrapper::FreeThreadResources() { |
4689 DCHECK(!IsActive()); | 4689 DCHECK(!IsActive()); |
4690 } | 4690 } |
4691 | 4691 |
4692 } // namespace internal | 4692 } // namespace internal |
4693 } // namespace v8 | 4693 } // namespace v8 |
OLD | NEW |