1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-11 10:18:15 +09:00

LibJS: Remove unnecessary FunctionObject::name() virtual

This allows us to remove the BoundFunction::m_name field, which we
were initializing with a formatted FlyString on every function binding,
despite never using it for anything.
This commit is contained in:
Andreas Kling 2025-04-09 22:31:12 +02:00 committed by Alexander Kalenik
parent 6bd2cf3195
commit 4a5863bcdb
Notes: github-actions[bot] 2025-04-10 02:01:55 +00:00
11 changed files with 5 additions and 26 deletions

View file

@ -34,7 +34,7 @@ public:
virtual ThrowCompletionOr<Value> call();
virtual ThrowCompletionOr<GC::Ref<Object>> construct(FunctionObject& new_target);
virtual FlyString const& name() const override { return m_name; }
FlyString const& name() const { return m_name; }
virtual bool is_strict_mode() const override;
virtual bool has_constructor() const override { return false; }
virtual Realm* realm() const override { return m_realm; }