1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 08:27:46 +00:00

LibJS: Cache valid indices in IndexedPropertyIterator

Refetching the list of indices every time we increment the iterator was
showing up hot & heavy in a profile of Discord.
This commit is contained in:
Andreas Kling 2022-02-05 17:59:14 +01:00
parent 483dce9750
commit 0d60cf211d
2 changed files with 5 additions and 3 deletions

View file

@ -106,6 +106,7 @@ private:
void skip_empty_indices();
const IndexedProperties& m_indexed_properties;
Vector<u32> m_cached_indices;
u32 m_index;
bool m_skip_empty;
};