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

Side by Side Diff: src/objects.h

Issue 1481493003: Fix JSFunction's in-object properties initialization. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Addressing comments 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 | « src/heap/heap.cc ('k') | src/objects-inl.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 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 2328 matching lines...) Expand 10 before | Expand all | Expand 10 after
2339 Object* value, 2339 Object* value,
2340 WriteBarrierMode mode 2340 WriteBarrierMode mode
2341 = UPDATE_WRITE_BARRIER); 2341 = UPDATE_WRITE_BARRIER);
2342 2342
2343 // Set the object's prototype (only JSReceiver and null are allowed values). 2343 // Set the object's prototype (only JSReceiver and null are allowed values).
2344 MUST_USE_RESULT static Maybe<bool> SetPrototype(Handle<JSObject> object, 2344 MUST_USE_RESULT static Maybe<bool> SetPrototype(Handle<JSObject> object,
2345 Handle<Object> value, 2345 Handle<Object> value,
2346 bool from_javascript, 2346 bool from_javascript,
2347 ShouldThrow should_throw); 2347 ShouldThrow should_throw);
2348 2348
2349 // Initializes the body after properties slot, properties slot is 2349 // Initializes the body starting at |start_offset|. It is responsibility of
2350 // initialized by set_properties. Fill the pre-allocated fields with 2350 // the caller to initialize object header. Fill the pre-allocated fields with
2351 // pre_allocated_value and the rest with filler_value. 2351 // pre_allocated_value and the rest with filler_value.
2352 // Note: this call does not update write barrier, the caller is responsible 2352 // Note: this call does not update write barrier, the caller is responsible
2353 // to ensure that |filler_value| can be collected without WB here. 2353 // to ensure that |filler_value| can be collected without WB here.
2354 inline void InitializeBody(Map* map, 2354 inline void InitializeBody(Map* map, int start_offset,
2355 Object* pre_allocated_value, 2355 Object* pre_allocated_value, Object* filler_value);
2356 Object* filler_value);
2357 2356
2358 // Check whether this object references another object 2357 // Check whether this object references another object
2359 bool ReferencesObject(Object* obj); 2358 bool ReferencesObject(Object* obj);
2360 2359
2361 MUST_USE_RESULT static Maybe<bool> PreventExtensions( 2360 MUST_USE_RESULT static Maybe<bool> PreventExtensions(
2362 Handle<JSObject> object, ShouldThrow should_throw); 2361 Handle<JSObject> object, ShouldThrow should_throw);
2363 2362
2364 static bool IsExtensible(Handle<JSObject> object); 2363 static bool IsExtensible(Handle<JSObject> object);
2365 2364
2366 // ES5 Object.seal 2365 // ES5 Object.seal
(...skipping 8372 matching lines...) Expand 10 before | Expand all | Expand 10 after
10739 } 10738 }
10740 return value; 10739 return value;
10741 } 10740 }
10742 }; 10741 };
10743 10742
10744 10743
10745 } // NOLINT, false-positive due to second-order macros. 10744 } // NOLINT, false-positive due to second-order macros.
10746 } // NOLINT, false-positive due to second-order macros. 10745 } // NOLINT, false-positive due to second-order macros.
10747 10746
10748 #endif // V8_OBJECTS_H_ 10747 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/heap/heap.cc ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698