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

Unified Diff: src/bootstrapper.cc

Issue 2590373002: [builtins] Add ReturnReceiver builtin (Closed)
Patch Set: remove builtins-iterator Created 4 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « BUILD.gn ('k') | src/builtins/builtins.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/bootstrapper.cc
diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc
index e20baf0ec8e6975961807fb487cc88df78825f90..6d2f545e825b0a8967b312d92a33314955de4e00 100644
--- a/src/bootstrapper.cc
+++ b/src/bootstrapper.cc
@@ -702,7 +702,7 @@ void Genesis::CreateIteratorMaps(Handle<JSFunction> empty) {
Handle<JSFunction> iterator_prototype_iterator = SimpleCreateFunction(
isolate(), factory()->NewStringFromAsciiChecked("[Symbol.iterator]"),
- Builtins::kIteratorPrototypeIterator, 0, true);
+ Builtins::kReturnReceiver, 0, true);
iterator_prototype_iterator->shared()->set_native(true);
JSObject::AddProperty(iterator_prototype, factory()->iterator_symbol(),
@@ -1883,6 +1883,10 @@ void Genesis::InitializeGlobal(Handle<JSGlobalObject> global_object,
SimpleInstallFunction(prototype, "catch", Builtins::kIllegal, 1, true,
DONT_ENUM);
+ SimpleInstallGetter(promise_fun, factory->symbol_species_string(),
+ factory->species_symbol(), Builtins::kReturnReceiver,
+ true);
+
Handle<Map> prototype_map(prototype->map());
Map::SetShouldBeFastPrototypeMap(prototype_map, true, isolate);
@@ -2070,10 +2074,9 @@ void Genesis::InitializeGlobal(Handle<JSGlobalObject> global_object,
{
// RegExp getters and setters.
- SimpleInstallGetter(regexp_fun,
- factory->InternalizeUtf8String("[Symbol.species]"),
- factory->species_symbol(),
- Builtins::kRegExpPrototypeSpeciesGetter, true);
+ SimpleInstallGetter(regexp_fun, factory->symbol_species_string(),
+ factory->species_symbol(), Builtins::kReturnReceiver,
+ true);
// Static properties set by a successful match.
« no previous file with comments | « BUILD.gn ('k') | src/builtins/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698