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

Side by Side Diff: src/objects-inl.h

Issue 1431443003: Refactor Object::SetSuperProperty and others. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Revert unintended change to test262 status file. Created 5 years, 1 month 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/objects.cc ('k') | src/runtime/runtime-classes.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 // Review notes: 5 // Review notes:
6 // 6 //
7 // - The use of macros in these inline functions may seem superfluous 7 // - The use of macros in these inline functions may seem superfluous
8 // but it is absolutely needed to make sure gcc generates optimal 8 // but it is absolutely needed to make sure gcc generates optimal
9 // code. gcc is not happy when attempting to inline too deep. 9 // code. gcc is not happy when attempting to inline too deep.
10 // 10 //
(...skipping 1177 matching lines...) Expand 10 before | Expand all | Expand 10 after
1188 LanguageMode language_mode) { 1188 LanguageMode language_mode) {
1189 LookupIterator it(isolate, object, index); 1189 LookupIterator it(isolate, object, index);
1190 return GetProperty(&it, language_mode); 1190 return GetProperty(&it, language_mode);
1191 } 1191 }
1192 1192
1193 1193
1194 MaybeHandle<Object> Object::SetElement(Isolate* isolate, Handle<Object> object, 1194 MaybeHandle<Object> Object::SetElement(Isolate* isolate, Handle<Object> object,
1195 uint32_t index, Handle<Object> value, 1195 uint32_t index, Handle<Object> value,
1196 LanguageMode language_mode) { 1196 LanguageMode language_mode) {
1197 LookupIterator it(isolate, object, index); 1197 LookupIterator it(isolate, object, index);
1198 return SetProperty(&it, value, language_mode, MAY_BE_STORE_FROM_KEYED); 1198 MAYBE_RETURN_NULL(
1199 SetProperty(&it, value, language_mode, MAY_BE_STORE_FROM_KEYED));
1200 return value;
1199 } 1201 }
1200 1202
1201 1203
1202 Handle<Object> Object::GetPrototype(Isolate* isolate, Handle<Object> obj) { 1204 Handle<Object> Object::GetPrototype(Isolate* isolate, Handle<Object> obj) {
1203 // We don't expect access checks to be needed on JSProxy objects. 1205 // We don't expect access checks to be needed on JSProxy objects.
1204 DCHECK(!obj->IsAccessCheckNeeded() || obj->IsJSObject()); 1206 DCHECK(!obj->IsAccessCheckNeeded() || obj->IsJSObject());
1205 Handle<Context> context(isolate->context()); 1207 Handle<Context> context(isolate->context());
1206 if (obj->IsAccessCheckNeeded() && 1208 if (obj->IsAccessCheckNeeded() &&
1207 !isolate->MayAccess(context, Handle<JSObject>::cast(obj))) { 1209 !isolate->MayAccess(context, Handle<JSObject>::cast(obj))) {
1208 return isolate->factory()->null_value(); 1210 return isolate->factory()->null_value();
(...skipping 6923 matching lines...) Expand 10 before | Expand all | Expand 10 after
8132 #undef WRITE_INT64_FIELD 8134 #undef WRITE_INT64_FIELD
8133 #undef READ_BYTE_FIELD 8135 #undef READ_BYTE_FIELD
8134 #undef WRITE_BYTE_FIELD 8136 #undef WRITE_BYTE_FIELD
8135 #undef NOBARRIER_READ_BYTE_FIELD 8137 #undef NOBARRIER_READ_BYTE_FIELD
8136 #undef NOBARRIER_WRITE_BYTE_FIELD 8138 #undef NOBARRIER_WRITE_BYTE_FIELD
8137 8139
8138 } // namespace internal 8140 } // namespace internal
8139 } // namespace v8 8141 } // namespace v8
8140 8142
8141 #endif // V8_OBJECTS_INL_H_ 8143 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects.cc ('k') | src/runtime/runtime-classes.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698