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

Side by Side Diff: src/objects.cc

Issue 1224523002: Avoid converting key to string for deleting of elements (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 5 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 | « src/messages.h ('k') | src/runtime.js » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 <iomanip> 5 #include <iomanip>
6 #include <sstream> 6 #include <sstream>
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 9
10 #include "src/accessors.h" 10 #include "src/accessors.h"
(...skipping 5262 matching lines...) Expand 10 before | Expand all | Expand 10 after
5273 } 5273 }
5274 } 5274 }
5275 5275
5276 return it->factory()->true_value(); 5276 return it->factory()->true_value();
5277 } 5277 }
5278 5278
5279 5279
5280 MaybeHandle<Object> JSReceiver::DeleteElement(Handle<JSReceiver> object, 5280 MaybeHandle<Object> JSReceiver::DeleteElement(Handle<JSReceiver> object,
5281 uint32_t index, 5281 uint32_t index,
5282 LanguageMode language_mode) { 5282 LanguageMode language_mode) {
5283 LookupIterator it(object->GetIsolate(), object, index); 5283 LookupIterator it(object->GetIsolate(), object, index,
5284 LookupIterator::HIDDEN);
5284 return DeleteProperty(&it, language_mode); 5285 return DeleteProperty(&it, language_mode);
5285 } 5286 }
5286 5287
5287 5288
5288 MaybeHandle<Object> JSReceiver::DeleteProperty(Handle<JSReceiver> object, 5289 MaybeHandle<Object> JSReceiver::DeleteProperty(Handle<JSReceiver> object,
5289 Handle<Name> name, 5290 Handle<Name> name,
5290 LanguageMode language_mode) { 5291 LanguageMode language_mode) {
5291 LookupIterator it(object, name, LookupIterator::HIDDEN); 5292 LookupIterator it(object, name, LookupIterator::HIDDEN);
5292 return JSObject::DeleteProperty(&it, language_mode); 5293 return JSObject::DeleteProperty(&it, language_mode);
5293 } 5294 }
(...skipping 10890 matching lines...) Expand 10 before | Expand all | Expand 10 after
16184 Handle<Object> new_value) { 16185 Handle<Object> new_value) {
16185 if (cell->value() != *new_value) { 16186 if (cell->value() != *new_value) {
16186 cell->set_value(*new_value); 16187 cell->set_value(*new_value);
16187 Isolate* isolate = cell->GetIsolate(); 16188 Isolate* isolate = cell->GetIsolate();
16188 cell->dependent_code()->DeoptimizeDependentCodeGroup( 16189 cell->dependent_code()->DeoptimizeDependentCodeGroup(
16189 isolate, DependentCode::kPropertyCellChangedGroup); 16190 isolate, DependentCode::kPropertyCellChangedGroup);
16190 } 16191 }
16191 } 16192 }
16192 } // namespace internal 16193 } // namespace internal
16193 } // namespace v8 16194 } // namespace v8
OLDNEW
« no previous file with comments | « src/messages.h ('k') | src/runtime.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698