wasm: nicer debug output for Let statements

This commit is contained in:
Brian Carroll 2022-08-04 12:30:14 +01:00
parent 67f7512e6d
commit 7f44ace383
No known key found for this signature in database
GPG key ID: 5C7B2EC4101703C0

View file

@ -715,7 +715,7 @@ impl<'a> WasmBackend<'a> {
let mut current_stmt = stmt;
while let Stmt::Let(sym, expr, layout, following) = current_stmt {
if DEBUG_SETTINGS.let_stmt_ir {
println!("let {:?} = {}", sym, expr.to_pretty(200)); // ignore `following`! Too confusing otherwise.
print!("\nlet {:?} = {}", sym, expr.to_pretty(200));
}
let kind = match following {