mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 01:35:08 +02:00
LibJS/Bytecode: Make compilation use SharedFunctionInstanceData instead
All the data we need for compilation is in SharedFunctionInstanceData, so we shouldn't depend on ECMAScriptFunctionObject. Allows NativeJavaScriptBackedFunction to compile bytecode.
This commit is contained in:
committed by
Andreas Kling
parent
2d15326f5d
commit
354888640d
Notes:
github-actions[bot]
2025-11-30 10:56:27 +00:00
Author: https://github.com/Lubrsi Commit: https://github.com/LadybirdBrowser/ladybird/commit/354888640de Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6728 Reviewed-by: https://github.com/Hendiadyoin1 Reviewed-by: https://github.com/awesomekling
@@ -217,7 +217,7 @@ ThrowCompletionOr<void> ECMAScriptFunctionObject::get_stack_frame_size(size_t& r
|
||||
if (is_module_wrapper()) {
|
||||
executable = TRY(Bytecode::compile(vm(), ecmascript_code(), kind(), name()));
|
||||
} else {
|
||||
executable = TRY(Bytecode::compile(vm(), *this));
|
||||
executable = TRY(Bytecode::compile(vm(), shared_data()));
|
||||
}
|
||||
}
|
||||
registers_and_constants_and_locals_count = executable->registers_and_constants_and_locals_count;
|
||||
|
||||
Reference in New Issue
Block a user