OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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_LOOKUP_INL_H_ | 5 #ifndef V8_LOOKUP_INL_H_ |
6 #define V8_LOOKUP_INL_H_ | 6 #define V8_LOOKUP_INL_H_ |
7 | 7 |
8 #include "src/lookup.h" | 8 #include "src/lookup.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 20 matching lines...) Expand all Loading... |
31 } | 31 } |
32 | 32 |
33 | 33 |
34 LookupIterator::State LookupIterator::LookupInHolder(Map* map, | 34 LookupIterator::State LookupIterator::LookupInHolder(Map* map, |
35 JSReceiver* holder) { | 35 JSReceiver* holder) { |
36 STATIC_ASSERT(INTERCEPTOR == BEFORE_PROPERTY); | 36 STATIC_ASSERT(INTERCEPTOR == BEFORE_PROPERTY); |
37 DisallowHeapAllocation no_gc; | 37 DisallowHeapAllocation no_gc; |
38 switch (state_) { | 38 switch (state_) { |
39 case NOT_FOUND: | 39 case NOT_FOUND: |
40 if (map->IsJSProxyMap()) return JSPROXY; | 40 if (map->IsJSProxyMap()) return JSPROXY; |
41 if (map->is_access_check_needed()) return ACCESS_CHECK; | 41 if (map->is_access_check_needed() && |
| 42 !isolate_->IsInternallyUsedPropertyName(name_)) { |
| 43 return ACCESS_CHECK; |
| 44 } |
42 // Fall through. | 45 // Fall through. |
43 case ACCESS_CHECK: | 46 case ACCESS_CHECK: |
44 if (check_interceptor() && map->has_named_interceptor()) { | 47 if (check_interceptor() && map->has_named_interceptor()) { |
45 return INTERCEPTOR; | 48 return INTERCEPTOR; |
46 } | 49 } |
47 // Fall through. | 50 // Fall through. |
48 case INTERCEPTOR: | 51 case INTERCEPTOR: |
49 if (map->is_dictionary_map()) { | 52 if (map->is_dictionary_map()) { |
50 NameDictionary* dict = JSObject::cast(holder)->property_dictionary(); | 53 NameDictionary* dict = JSObject::cast(holder)->property_dictionary(); |
51 number_ = dict->FindEntry(name_); | 54 number_ = dict->FindEntry(name_); |
(...skipping 24 matching lines...) Expand all Loading... |
76 case TRANSITION: | 79 case TRANSITION: |
77 UNREACHABLE(); | 80 UNREACHABLE(); |
78 } | 81 } |
79 UNREACHABLE(); | 82 UNREACHABLE(); |
80 return state_; | 83 return state_; |
81 } | 84 } |
82 } | 85 } |
83 } // namespace v8::internal | 86 } // namespace v8::internal |
84 | 87 |
85 #endif // V8_LOOKUP_INL_H_ | 88 #endif // V8_LOOKUP_INL_H_ |
OLD | NEW |