mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 18:17:22 +02:00
After successful bytecode compilation, the m_functions_to_initialize and m_var_names_to_initialize_binding vectors are no longer needed as they are only consumed by emit_function_declaration_instantiation() during code generation. Add clear_compile_inputs() to release these vectors post-compile, and call it from both ECMAScriptFunctionObject::get_stack_frame_size() and NativeJavaScriptBackedFunction::bytecode_executable() after their respective lazy compilation succeeds. Also add a pre-compile assertion in Generator::generate_from_function() to verify we never try to compile the same function data twice, and a VERIFY in ECMAScriptFunctionObject::ecmascript_code() to guard against null dereference.
1.4 KiB
1.4 KiB