| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 5022 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5033 } else { | 5033 } else { |
| 5034 return static_cast<uint32_t>(length->Number()); | 5034 return static_cast<uint32_t>(length->Number()); |
| 5035 } | 5035 } |
| 5036 } | 5036 } |
| 5037 | 5037 |
| 5038 | 5038 |
| 5039 Local<Object> Array::CloneElementAt(uint32_t index) { | 5039 Local<Object> Array::CloneElementAt(uint32_t index) { |
| 5040 i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate(); | 5040 i::Isolate* isolate = Utils::OpenHandle(this)->GetIsolate(); |
| 5041 ON_BAILOUT(isolate, "v8::Array::CloneElementAt()", return Local<Object>()); | 5041 ON_BAILOUT(isolate, "v8::Array::CloneElementAt()", return Local<Object>()); |
| 5042 i::Handle<i::JSObject> self = Utils::OpenHandle(this); | 5042 i::Handle<i::JSObject> self = Utils::OpenHandle(this); |
| 5043 if (!self->HasFastElements()) { | 5043 if (!self->HasFastObjectElements()) { |
| 5044 return Local<Object>(); | 5044 return Local<Object>(); |
| 5045 } | 5045 } |
| 5046 i::FixedArray* elms = i::FixedArray::cast(self->elements()); | 5046 i::FixedArray* elms = i::FixedArray::cast(self->elements()); |
| 5047 i::Object* paragon = elms->get(index); | 5047 i::Object* paragon = elms->get(index); |
| 5048 if (!paragon->IsJSObject()) { | 5048 if (!paragon->IsJSObject()) { |
| 5049 return Local<Object>(); | 5049 return Local<Object>(); |
| 5050 } | 5050 } |
| 5051 i::Handle<i::JSObject> paragon_handle(i::JSObject::cast(paragon)); | 5051 i::Handle<i::JSObject> paragon_handle(i::JSObject::cast(paragon)); |
| 5052 EXCEPTION_PREAMBLE(isolate); | 5052 EXCEPTION_PREAMBLE(isolate); |
| 5053 ENTER_V8(isolate); | 5053 ENTER_V8(isolate); |
| (...skipping 1357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6411 | 6411 |
| 6412 | 6412 |
| 6413 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { | 6413 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { |
| 6414 HandleScopeImplementer* scope_implementer = | 6414 HandleScopeImplementer* scope_implementer = |
| 6415 reinterpret_cast<HandleScopeImplementer*>(storage); | 6415 reinterpret_cast<HandleScopeImplementer*>(storage); |
| 6416 scope_implementer->IterateThis(v); | 6416 scope_implementer->IterateThis(v); |
| 6417 return storage + ArchiveSpacePerThread(); | 6417 return storage + ArchiveSpacePerThread(); |
| 6418 } | 6418 } |
| 6419 | 6419 |
| 6420 } } // namespace v8::internal | 6420 } } // namespace v8::internal |
| OLD | NEW |