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

Side by Side Diff: src/objects.cc

Issue 1178953003: Reconfigure on the right holder, which might be a hidden object. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 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 | « no previous file | no next file » | 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 4162 matching lines...) Expand 10 before | Expand all | Expand 10 after
4173 it->isolate(), Handle<ExecutableAccessorInfo>::cast(accessors)); 4173 it->isolate(), Handle<ExecutableAccessorInfo>::cast(accessors));
4174 new_data->set_property_attributes(attributes); 4174 new_data->set_property_attributes(attributes);
4175 // By clearing the setter we don't have to introduce a lookup to 4175 // By clearing the setter we don't have to introduce a lookup to
4176 // the setter, simply make it unavailable to reflect the 4176 // the setter, simply make it unavailable to reflect the
4177 // attributes. 4177 // attributes.
4178 if (attributes & READ_ONLY) { 4178 if (attributes & READ_ONLY) {
4179 ExecutableAccessorInfo::ClearSetter(new_data); 4179 ExecutableAccessorInfo::ClearSetter(new_data);
4180 } 4180 }
4181 4181
4182 if (it->IsElement()) { 4182 if (it->IsElement()) {
4183 SetElementCallback(object, it->index(), new_data, attributes); 4183 SetElementCallback(it->GetHolder<JSObject>(), it->index(), new_data,
4184 attributes);
4184 } else { 4185 } else {
4185 SetPropertyCallback(object, it->name(), new_data, attributes); 4186 SetPropertyCallback(it->GetHolder<JSObject>(), it->name(), new_data,
4187 attributes);
4186 } 4188 }
4187 if (is_observed) { 4189 if (is_observed) {
4188 RETURN_ON_EXCEPTION( 4190 RETURN_ON_EXCEPTION(
4189 it->isolate(), 4191 it->isolate(),
4190 EnqueueChangeRecord(object, "reconfigure", it->GetName(), 4192 EnqueueChangeRecord(object, "reconfigure", it->GetName(),
4191 it->factory()->the_hole_value()), 4193 it->factory()->the_hole_value()),
4192 Object); 4194 Object);
4193 } 4195 }
4194 return value; 4196 return value;
4195 } 4197 }
(...skipping 12530 matching lines...) Expand 10 before | Expand all | Expand 10 after
16726 Handle<Object> new_value) { 16728 Handle<Object> new_value) {
16727 if (cell->value() != *new_value) { 16729 if (cell->value() != *new_value) {
16728 cell->set_value(*new_value); 16730 cell->set_value(*new_value);
16729 Isolate* isolate = cell->GetIsolate(); 16731 Isolate* isolate = cell->GetIsolate();
16730 cell->dependent_code()->DeoptimizeDependentCodeGroup( 16732 cell->dependent_code()->DeoptimizeDependentCodeGroup(
16731 isolate, DependentCode::kPropertyCellChangedGroup); 16733 isolate, DependentCode::kPropertyCellChangedGroup);
16732 } 16734 }
16733 } 16735 }
16734 } // namespace internal 16736 } // namespace internal
16735 } // namespace v8 16737 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698