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

Side by Side Diff: src/objects.h

Issue 1484473002: Fix Reflect.construct wrt proxy, generator, and non-subclass new.target (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | src/objects.cc » ('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 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 #ifndef V8_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 7280 matching lines...) Expand 10 before | Expand all | Expand 10 after
7291 7291
7292 inline BindingsArray* function_bindings(); 7292 inline BindingsArray* function_bindings();
7293 inline void set_function_bindings(BindingsArray* bindings); 7293 inline void set_function_bindings(BindingsArray* bindings);
7294 7294
7295 // The initial map for an object created by this constructor. 7295 // The initial map for an object created by this constructor.
7296 inline Map* initial_map(); 7296 inline Map* initial_map();
7297 static void SetInitialMap(Handle<JSFunction> function, Handle<Map> map, 7297 static void SetInitialMap(Handle<JSFunction> function, Handle<Map> map,
7298 Handle<Object> prototype); 7298 Handle<Object> prototype);
7299 inline bool has_initial_map(); 7299 inline bool has_initial_map();
7300 static void EnsureHasInitialMap(Handle<JSFunction> function); 7300 static void EnsureHasInitialMap(Handle<JSFunction> function);
7301 // Ensures that the |new_target| has correct initial map and 7301
7302 // returns it. If the |new_target| is not a subclass constructor 7302 // Creates a map that matches the constructor's initial map, but with
7303 // its initial map is left unmodified. 7303 // [[prototype]] being new.target.prototype. Because new.target can be a
7304 static Handle<Map> EnsureDerivedHasInitialMap(Handle<JSFunction> new_target, 7304 // JSProxy, this can call back into JavaScript.
7305 Handle<JSFunction> constructor); 7305 static MUST_USE_RESULT MaybeHandle<Map> GetDerivedMap(
7306 Isolate* isolate, Handle<JSFunction> constructor,
7307 Handle<JSReceiver> new_target);
7306 7308
7307 // Get and set the prototype property on a JSFunction. If the 7309 // Get and set the prototype property on a JSFunction. If the
7308 // function has an initial map the prototype is set on the initial 7310 // function has an initial map the prototype is set on the initial
7309 // map. Otherwise, the prototype is put in the initial map field 7311 // map. Otherwise, the prototype is put in the initial map field
7310 // until an initial map is needed. 7312 // until an initial map is needed.
7311 inline bool has_prototype(); 7313 inline bool has_prototype();
7312 inline bool has_instance_prototype(); 7314 inline bool has_instance_prototype();
7313 inline Object* prototype(); 7315 inline Object* prototype();
7314 inline Object* instance_prototype(); 7316 inline Object* instance_prototype();
7315 static void SetPrototype(Handle<JSFunction> function, 7317 static void SetPrototype(Handle<JSFunction> function,
(...skipping 3405 matching lines...) Expand 10 before | Expand all | Expand 10 after
10721 } 10723 }
10722 return value; 10724 return value;
10723 } 10725 }
10724 }; 10726 };
10725 10727
10726 10728
10727 } // NOLINT, false-positive due to second-order macros. 10729 } // NOLINT, false-positive due to second-order macros.
10728 } // NOLINT, false-positive due to second-order macros. 10730 } // NOLINT, false-positive due to second-order macros.
10729 10731
10730 #endif // V8_OBJECTS_H_ 10732 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « no previous file | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698