mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-10 13:00:29 +03:00
LibWasm: Print the block type for structured arguments
This commit is contained in:
parent
76ed7f2b20
commit
d471405caf
Notes:
sideshowbarker
2024-07-17 22:32:24 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/d471405caf3 Pull-request: https://github.com/SerenityOS/serenity/pull/11215 Reviewed-by: https://github.com/ADKaster
@ -434,7 +434,13 @@ void Printer::print(Wasm::Instruction const& instruction)
|
||||
[&](TableIndex const& index) { print("(table index {})", index.value()); },
|
||||
[&](Instruction::IndirectCallArgs const& args) { print("(indirect (type index {}) (table index {}))", args.type.value(), args.table.value()); },
|
||||
[&](Instruction::MemoryArgument const& args) { print("(memory (align {}) (offset {}))", args.align, args.offset); },
|
||||
[&](Instruction::StructuredInstructionArgs const& args) { print("(structured (else {}) (end {}))", args.else_ip.has_value() ? String::number(args.else_ip->value()) : "(none)", args.end_ip.value()); },
|
||||
[&](Instruction::StructuredInstructionArgs const& args) {
|
||||
print("(structured\n");
|
||||
TemporaryChange change { m_indent, m_indent + 1 };
|
||||
print(args.block_type);
|
||||
print_indent();
|
||||
print("(else {}) (end {}))", args.else_ip.has_value() ? String::number(args.else_ip->value()) : "(none)", args.end_ip.value());
|
||||
},
|
||||
[&](Instruction::TableBranchArgs const& args) {
|
||||
print("(table_branch");
|
||||
for (auto& label : args.labels)
|
||||
|
Loading…
Reference in New Issue
Block a user