mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 19:59:17 +00:00
LibJS: NewClass bytecode instruction
This adds a the NewClass bytecode instruction, enough of it is implemented for it to show it in the bytecode (js -d).
This commit is contained in:
parent
3694b8b690
commit
f6028c2534
Notes:
sideshowbarker
2024-07-19 17:26:41 +09:00
Author: https://github.com/jdahlin 🔰
Commit: f6028c2534
Pull-request: https://github.com/SerenityOS/serenity/pull/8343
6 changed files with 37 additions and 1 deletions
|
@ -452,6 +452,11 @@ void IteratorResultValue::execute_impl(Bytecode::Interpreter& interpreter) const
|
|||
interpreter.accumulator() = iterator_value(interpreter.global_object(), *iterator_result);
|
||||
}
|
||||
|
||||
void NewClass::execute_impl(Bytecode::Interpreter&) const
|
||||
{
|
||||
TODO();
|
||||
}
|
||||
|
||||
String Load::to_string_impl(Bytecode::Executable const&) const
|
||||
{
|
||||
return String::formatted("Load {}", m_src);
|
||||
|
@ -598,6 +603,11 @@ String NewFunction::to_string_impl(Bytecode::Executable const&) const
|
|||
return "NewFunction";
|
||||
}
|
||||
|
||||
String NewClass::to_string_impl(Bytecode::Executable const&) const
|
||||
{
|
||||
return "NewClass";
|
||||
}
|
||||
|
||||
String Return::to_string_impl(Bytecode::Executable const&) const
|
||||
{
|
||||
return "Return";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue