mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-21 12:05:15 +00:00
LibJS: GlobalObject needs to mark the iterator prototypes
Otherwise they all disappear in the first garbage collection.
This commit is contained in:
parent
b32c0c8181
commit
3143fea1eb
Notes:
sideshowbarker
2024-07-19 02:49:42 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/3143fea1ebb
1 changed files with 5 additions and 0 deletions
|
@ -143,6 +143,11 @@ void GlobalObject::visit_children(Visitor& visitor)
|
|||
visitor.visit(m_##snake_name##_constructor);
|
||||
JS_ENUMERATE_ERROR_SUBCLASSES
|
||||
#undef __JS_ENUMERATE
|
||||
|
||||
#define __JS_ENUMERATE(ClassName, snake_name) \
|
||||
visitor.visit(m_##snake_name##_prototype);
|
||||
JS_ENUMERATE_ITERATOR_PROTOTYPES
|
||||
#undef __JS_ENUMERATE
|
||||
}
|
||||
|
||||
JS_DEFINE_NATIVE_FUNCTION(GlobalObject::gc)
|
||||
|
|
Loading…
Add table
Reference in a new issue