mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-28 02:27:19 +02:00
LibJS+LibWeb: Return Vector<PropertyKey> from internal_own_property_keys
By doing that we avoid lots of `PropertyKey` -> `Value` -> `PropertyKey` transforms, which are quite expensive because of underlying `FlyString` -> `PrimitiveString` -> `FlyString` conversions. 10% improvement on MicroBench/object-keys.js
This commit is contained in:
committed by
Alexander Kalenik
parent
47569c1714
commit
5ee810f772
Notes:
github-actions[bot]
2025-05-15 18:13:23 +00:00
Author: https://github.com/kalenikaliaksandr Commit: https://github.com/LadybirdBrowser/ladybird/commit/5ee810f7721 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4733
@@ -21,6 +21,6 @@ bool is_platform_object_same_origin(JS::Object const&);
|
||||
Optional<JS::PropertyDescriptor> cross_origin_get_own_property_helper(Variant<HTML::Location*, HTML::Window*> const&, JS::PropertyKey const&);
|
||||
JS::ThrowCompletionOr<JS::Value> cross_origin_get(JS::VM&, JS::Object const&, JS::PropertyKey const&, JS::Value receiver);
|
||||
JS::ThrowCompletionOr<bool> cross_origin_set(JS::VM&, JS::Object&, JS::PropertyKey const&, JS::Value, JS::Value receiver);
|
||||
GC::RootVector<JS::Value> cross_origin_own_property_keys(Variant<HTML::Location const*, HTML::Window const*> const&);
|
||||
Vector<JS::PropertyKey> cross_origin_own_property_keys(Variant<HTML::Location const*, HTML::Window const*> const&);
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user