| 25 | } |
| 26 | |
| 27 | IV_LV5_INTERNAL_METHOD bool GetOwnIndexedPropertySlotMethod(const JSObject* obj, |
| 28 | Context* ctx, |
| 29 | uint32_t index, Slot* slot) { |
| 30 | JSString* value = static_cast<const JSStringObject*>(obj)->value(); |
| 31 | const std::size_t len = value->size(); |
| 32 | if (index < len) { |
| 33 | slot->set(JSString::NewSingle(ctx, value->At(index)), Attributes::String::Indexed(), obj); |
| 34 | return true; |
| 35 | } |
| 36 | return JSObject::GetOwnIndexedPropertySlotMethod(obj, ctx, index, slot); |
| 37 | } |
| 38 | |
| 39 | IV_LV5_INTERNAL_METHOD void GetOwnPropertyNamesMethod(const JSObject* obj, |
| 40 | Context* ctx, |