OLD | NEW |
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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
8 #include "src/api.h" | 8 #include "src/api.h" |
9 #include "src/arguments.h" | 9 #include "src/arguments.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
204 return; | 204 return; |
205 case LookupIterator::INTERCEPTOR: { | 205 case LookupIterator::INTERCEPTOR: { |
206 // If there is a getter, return; otherwise loop to perform the lookup. | 206 // If there is a getter, return; otherwise loop to perform the lookup. |
207 Handle<JSObject> holder = it->GetHolder<JSObject>(); | 207 Handle<JSObject> holder = it->GetHolder<JSObject>(); |
208 if (!holder->GetNamedInterceptor()->getter()->IsUndefined()) { | 208 if (!holder->GetNamedInterceptor()->getter()->IsUndefined()) { |
209 return; | 209 return; |
210 } | 210 } |
211 break; | 211 break; |
212 } | 212 } |
213 case LookupIterator::ACCESS_CHECK: | 213 case LookupIterator::ACCESS_CHECK: |
| 214 // PropertyHandlerCompiler::CheckPrototypes() knows how to emit |
| 215 // access checks for global proxies. |
| 216 if (it->GetHolder<JSObject>()->IsJSGlobalProxy() && |
| 217 it->HasAccess(v8::ACCESS_GET)) { |
| 218 break; |
| 219 } |
214 return; | 220 return; |
215 case LookupIterator::PROPERTY: | 221 case LookupIterator::PROPERTY: |
216 if (it->HasProperty()) return; // Yay! | 222 if (it->HasProperty()) return; // Yay! |
217 break; | 223 break; |
218 } | 224 } |
219 } | 225 } |
220 } | 226 } |
221 | 227 |
222 | 228 |
223 bool IC::TryRemoveInvalidPrototypeDependentStub(Handle<Object> receiver, | 229 bool IC::TryRemoveInvalidPrototypeDependentStub(Handle<Object> receiver, |
(...skipping 2837 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3061 #undef ADDR | 3067 #undef ADDR |
3062 }; | 3068 }; |
3063 | 3069 |
3064 | 3070 |
3065 Address IC::AddressFromUtilityId(IC::UtilityId id) { | 3071 Address IC::AddressFromUtilityId(IC::UtilityId id) { |
3066 return IC_utilities[id]; | 3072 return IC_utilities[id]; |
3067 } | 3073 } |
3068 | 3074 |
3069 | 3075 |
3070 } } // namespace v8::internal | 3076 } } // namespace v8::internal |
OLD | NEW |