mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-27 10:29:23 +00:00
LibJS+LibWeb: Use GC::Weak instead of AK::WeakPtr for GC-allocated types
This makes some common types like JS::Object smaller (by 8 bytes) and yields a minor speed improvement on many benchmarks.
This commit is contained in:
parent
25a5ed94d6
commit
dfa796a4e4
Notes:
github-actions[bot]
2025-10-17 15:25:08 +00:00
Author: https://github.com/awesomekling
Commit: dfa796a4e4
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6496
36 changed files with 111 additions and 115 deletions
|
|
@ -8,7 +8,7 @@
|
|||
#pragma once
|
||||
|
||||
#include <AK/String.h>
|
||||
#include <AK/WeakPtr.h>
|
||||
#include <LibGC/Weak.h>
|
||||
#include <LibWeb/Bindings/HTMLFormElementPrototype.h>
|
||||
#include <LibWeb/DOM/InputEventsTarget.h>
|
||||
#include <LibWeb/Export.h>
|
||||
|
|
@ -178,7 +178,7 @@ protected:
|
|||
private:
|
||||
void reset_form_owner();
|
||||
|
||||
WeakPtr<HTMLFormElement> m_form;
|
||||
GC::Weak<HTMLFormElement> m_form;
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#parser-inserted-flag
|
||||
bool m_parser_inserted { false };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue