mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 15:57:34 +00:00
LibJS: Add fast path for magical "length" property in LengthOfArrayLike
For Array objects, we can avoid a generic Get here since we know it has magical "length" behavior anyway.
This commit is contained in:
parent
8e5f201e59
commit
73ceb475b9
2 changed files with 5 additions and 0 deletions
|
@ -224,6 +224,7 @@ public:
|
|||
static FlatPtr may_interfere_with_indexed_property_access_offset() { return OFFSET_OF(Object, m_may_interfere_with_indexed_property_access); }
|
||||
static FlatPtr indexed_properties_offset() { return OFFSET_OF(Object, m_indexed_properties); }
|
||||
|
||||
[[nodiscard]] bool has_magical_length_property() const { return m_has_magical_length_property; }
|
||||
static FlatPtr has_magical_length_property_offset() { return OFFSET_OF(Object, m_has_magical_length_property); }
|
||||
|
||||
[[nodiscard]] bool is_typed_array() const { return m_is_typed_array; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue