Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: src/bootstrapper.cc

Issue 2732823002: [typedarrays] Move %TypedArray%.prototype.includes to C++ builtins (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | src/builtins/builtins.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 2594 matching lines...) Expand 10 before | Expand all | Expand 10 after
2605 Handle<JSFunction> values = 2605 Handle<JSFunction> values =
2606 SimpleInstallFunction(prototype, factory->values_string(), 2606 SimpleInstallFunction(prototype, factory->values_string(),
2607 Builtins::kTypedArrayPrototypeValues, 0, true); 2607 Builtins::kTypedArrayPrototypeValues, 0, true);
2608 values->shared()->set_builtin_function_id(kTypedArrayValues); 2608 values->shared()->set_builtin_function_id(kTypedArrayValues);
2609 JSObject::AddProperty(prototype, factory->iterator_symbol(), values, 2609 JSObject::AddProperty(prototype, factory->iterator_symbol(), values,
2610 DONT_ENUM); 2610 DONT_ENUM);
2611 2611
2612 // TODO(caitp): alphasort accessors/methods 2612 // TODO(caitp): alphasort accessors/methods
2613 SimpleInstallFunction(prototype, "copyWithin", 2613 SimpleInstallFunction(prototype, "copyWithin",
2614 Builtins::kTypedArrayPrototypeCopyWithin, 2, false); 2614 Builtins::kTypedArrayPrototypeCopyWithin, 2, false);
2615 SimpleInstallFunction(prototype, "includes",
2616 Builtins::kTypedArrayPrototypeIncludes, 1, false);
2615 } 2617 }
2616 2618
2617 { // -- T y p e d A r r a y s 2619 { // -- T y p e d A r r a y s
2618 #define INSTALL_TYPED_ARRAY(Type, type, TYPE, ctype, size) \ 2620 #define INSTALL_TYPED_ARRAY(Type, type, TYPE, ctype, size) \
2619 { \ 2621 { \
2620 Handle<JSFunction> fun; \ 2622 Handle<JSFunction> fun; \
2621 InstallTypedArray(#Type "Array", TYPE##_ELEMENTS, &fun); \ 2623 InstallTypedArray(#Type "Array", TYPE##_ELEMENTS, &fun); \
2622 InstallWithIntrinsicDefaultProto(isolate, fun, \ 2624 InstallWithIntrinsicDefaultProto(isolate, fun, \
2623 Context::TYPE##_ARRAY_FUN_INDEX); \ 2625 Context::TYPE##_ARRAY_FUN_INDEX); \
2624 } 2626 }
(...skipping 2482 matching lines...) Expand 10 before | Expand all | Expand 10 after
5107 } 5109 }
5108 5110
5109 5111
5110 // Called when the top-level V8 mutex is destroyed. 5112 // Called when the top-level V8 mutex is destroyed.
5111 void Bootstrapper::FreeThreadResources() { 5113 void Bootstrapper::FreeThreadResources() {
5112 DCHECK(!IsActive()); 5114 DCHECK(!IsActive());
5113 } 5115 }
5114 5116
5115 } // namespace internal 5117 } // namespace internal
5116 } // namespace v8 5118 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/builtins/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698