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

Side by Side Diff: src/objects.cc

Issue 1034513002: fix attribute lookup for all can read indexed interceptors (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 9 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 | test/cctest/test-api-interceptors.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 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 599 matching lines...) Expand 10 before | Expand all | Expand 10 after
610 Isolate* isolate, Handle<JSObject> object, Handle<Object> receiver, 610 Isolate* isolate, Handle<JSObject> object, Handle<Object> receiver,
611 uint32_t index) { 611 uint32_t index) {
612 Handle<JSObject> holder = object; 612 Handle<JSObject> holder = object;
613 PrototypeIterator::WhereToStart where_to_start = 613 PrototypeIterator::WhereToStart where_to_start =
614 PrototypeIterator::START_AT_RECEIVER; 614 PrototypeIterator::START_AT_RECEIVER;
615 while (true) { 615 while (true) {
616 auto all_can_read_holder = 616 auto all_can_read_holder =
617 FindIndexedAllCanReadHolder(isolate, holder, where_to_start); 617 FindIndexedAllCanReadHolder(isolate, holder, where_to_start);
618 if (!all_can_read_holder.ToHandle(&holder)) break; 618 if (!all_can_read_holder.ToHandle(&holder)) break;
619 auto result = 619 auto result =
620 JSObject::GetElementAttributeFromInterceptor(object, receiver, index); 620 JSObject::GetElementAttributeFromInterceptor(holder, receiver, index);
621 if (isolate->has_scheduled_exception()) break; 621 if (isolate->has_scheduled_exception()) break;
622 if (result.IsJust() && result.FromJust() != ABSENT) return result; 622 if (result.IsJust() && result.FromJust() != ABSENT) return result;
623 where_to_start = PrototypeIterator::START_AT_PROTOTYPE; 623 where_to_start = PrototypeIterator::START_AT_PROTOTYPE;
624 } 624 }
625 isolate->ReportFailedAccessCheck(object); 625 isolate->ReportFailedAccessCheck(object);
626 RETURN_VALUE_IF_SCHEDULED_EXCEPTION(isolate, Nothing<PropertyAttributes>()); 626 RETURN_VALUE_IF_SCHEDULED_EXCEPTION(isolate, Nothing<PropertyAttributes>());
627 return Just(ABSENT); 627 return Just(ABSENT);
628 } 628 }
629 629
630 630
(...skipping 16475 matching lines...) Expand 10 before | Expand all | Expand 10 after
17106 CompilationInfo* info) { 17106 CompilationInfo* info) {
17107 Handle<DependentCode> codes = DependentCode::InsertCompilationInfo( 17107 Handle<DependentCode> codes = DependentCode::InsertCompilationInfo(
17108 handle(cell->dependent_code(), info->isolate()), 17108 handle(cell->dependent_code(), info->isolate()),
17109 DependentCode::kPropertyCellChangedGroup, info->object_wrapper()); 17109 DependentCode::kPropertyCellChangedGroup, info->object_wrapper());
17110 if (*codes != cell->dependent_code()) cell->set_dependent_code(*codes); 17110 if (*codes != cell->dependent_code()) cell->set_dependent_code(*codes);
17111 info->dependencies(DependentCode::kPropertyCellChangedGroup)->Add( 17111 info->dependencies(DependentCode::kPropertyCellChangedGroup)->Add(
17112 cell, info->zone()); 17112 cell, info->zone());
17113 } 17113 }
17114 17114
17115 } } // namespace v8::internal 17115 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | test/cctest/test-api-interceptors.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698