| OLD | NEW |
| 1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 2189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2200 | 2200 |
| 2201 Local<Value> v8::Object::GetRealNamedPropertyInPrototypeChain( | 2201 Local<Value> v8::Object::GetRealNamedPropertyInPrototypeChain( |
| 2202 Handle<String> key) { | 2202 Handle<String> key) { |
| 2203 ON_BAILOUT("v8::Object::GetRealNamedPropertyInPrototypeChain()", | 2203 ON_BAILOUT("v8::Object::GetRealNamedPropertyInPrototypeChain()", |
| 2204 return Local<Value>()); | 2204 return Local<Value>()); |
| 2205 ENTER_V8; | 2205 ENTER_V8; |
| 2206 i::Handle<i::JSObject> self_obj = Utils::OpenHandle(this); | 2206 i::Handle<i::JSObject> self_obj = Utils::OpenHandle(this); |
| 2207 i::Handle<i::String> key_obj = Utils::OpenHandle(*key); | 2207 i::Handle<i::String> key_obj = Utils::OpenHandle(*key); |
| 2208 i::LookupResult lookup; | 2208 i::LookupResult lookup; |
| 2209 self_obj->LookupRealNamedPropertyInPrototypes(*key_obj, &lookup); | 2209 self_obj->LookupRealNamedPropertyInPrototypes(*key_obj, &lookup); |
| 2210 if (lookup.IsValid()) { | 2210 if (lookup.IsProperty()) { |
| 2211 PropertyAttributes attributes; | 2211 PropertyAttributes attributes; |
| 2212 i::Handle<i::Object> result(self_obj->GetProperty(*self_obj, | 2212 i::Handle<i::Object> result(self_obj->GetProperty(*self_obj, |
| 2213 &lookup, | 2213 &lookup, |
| 2214 *key_obj, | 2214 *key_obj, |
| 2215 &attributes)); | 2215 &attributes)); |
| 2216 return Utils::ToLocal(result); | 2216 return Utils::ToLocal(result); |
| 2217 } | 2217 } |
| 2218 return Local<Value>(); // No real property was found in prototype chain. | 2218 return Local<Value>(); // No real property was found in prototype chain. |
| 2219 } | 2219 } |
| 2220 | 2220 |
| 2221 | 2221 |
| 2222 Local<Value> v8::Object::GetRealNamedProperty(Handle<String> key) { | 2222 Local<Value> v8::Object::GetRealNamedProperty(Handle<String> key) { |
| 2223 ON_BAILOUT("v8::Object::GetRealNamedProperty()", return Local<Value>()); | 2223 ON_BAILOUT("v8::Object::GetRealNamedProperty()", return Local<Value>()); |
| 2224 ENTER_V8; | 2224 ENTER_V8; |
| 2225 i::Handle<i::JSObject> self_obj = Utils::OpenHandle(this); | 2225 i::Handle<i::JSObject> self_obj = Utils::OpenHandle(this); |
| 2226 i::Handle<i::String> key_obj = Utils::OpenHandle(*key); | 2226 i::Handle<i::String> key_obj = Utils::OpenHandle(*key); |
| 2227 i::LookupResult lookup; | 2227 i::LookupResult lookup; |
| 2228 self_obj->LookupRealNamedProperty(*key_obj, &lookup); | 2228 self_obj->LookupRealNamedProperty(*key_obj, &lookup); |
| 2229 if (lookup.IsValid()) { | 2229 if (lookup.IsProperty()) { |
| 2230 PropertyAttributes attributes; | 2230 PropertyAttributes attributes; |
| 2231 i::Handle<i::Object> result(self_obj->GetProperty(*self_obj, | 2231 i::Handle<i::Object> result(self_obj->GetProperty(*self_obj, |
| 2232 &lookup, | 2232 &lookup, |
| 2233 *key_obj, | 2233 *key_obj, |
| 2234 &attributes)); | 2234 &attributes)); |
| 2235 return Utils::ToLocal(result); | 2235 return Utils::ToLocal(result); |
| 2236 } | 2236 } |
| 2237 return Local<Value>(); // No real property was found in prototype chain. | 2237 return Local<Value>(); // No real property was found in prototype chain. |
| 2238 } | 2238 } |
| 2239 | 2239 |
| (...skipping 1698 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3938 | 3938 |
| 3939 | 3939 |
| 3940 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { | 3940 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { |
| 3941 HandleScopeImplementer* thread_local = | 3941 HandleScopeImplementer* thread_local = |
| 3942 reinterpret_cast<HandleScopeImplementer*>(storage); | 3942 reinterpret_cast<HandleScopeImplementer*>(storage); |
| 3943 thread_local->IterateThis(v); | 3943 thread_local->IterateThis(v); |
| 3944 return storage + ArchiveSpacePerThread(); | 3944 return storage + ArchiveSpacePerThread(); |
| 3945 } | 3945 } |
| 3946 | 3946 |
| 3947 } } // namespace v8::internal | 3947 } } // namespace v8::internal |
| OLD | NEW |