mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 10:27:35 +00:00
LibJS: Rename Bytecode::ExecutionUnit => Bytecode::Executable
This commit is contained in:
parent
597e0d95fe
commit
b61f198d22
6 changed files with 14 additions and 14 deletions
|
@ -151,15 +151,15 @@ Value ScriptFunction::execute_function_body()
|
|||
|
||||
if (bytecode_interpreter) {
|
||||
prepare_arguments();
|
||||
if (!m_bytecode_execution_unit.has_value()) {
|
||||
m_bytecode_execution_unit = Bytecode::Generator::generate(m_body);
|
||||
if (!m_bytecode_executable.has_value()) {
|
||||
m_bytecode_executable = Bytecode::Generator::generate(m_body);
|
||||
if constexpr (JS_BYTECODE_DEBUG) {
|
||||
dbgln("Compiled Bytecode::Block for function '{}':", m_name);
|
||||
for (auto& block : m_bytecode_execution_unit->basic_blocks)
|
||||
for (auto& block : m_bytecode_executable->basic_blocks)
|
||||
block.dump();
|
||||
}
|
||||
}
|
||||
return bytecode_interpreter->run(*m_bytecode_execution_unit);
|
||||
return bytecode_interpreter->run(*m_bytecode_executable);
|
||||
} else {
|
||||
OwnPtr<Interpreter> local_interpreter;
|
||||
ast_interpreter = vm.interpreter_if_exists();
|
||||
|
|
|
@ -48,7 +48,7 @@ private:
|
|||
FlyString m_name;
|
||||
NonnullRefPtr<Statement> m_body;
|
||||
const Vector<FunctionNode::Parameter> m_parameters;
|
||||
Optional<Bytecode::ExecutionUnit> m_bytecode_execution_unit;
|
||||
Optional<Bytecode::Executable> m_bytecode_executable;
|
||||
ScopeObject* m_parent_scope { nullptr };
|
||||
i32 m_function_length { 0 };
|
||||
bool m_is_strict { false };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue