vfmt: print `or { }` on a single line
parent
73771b741c
commit
4403c76406
|
@ -1073,10 +1073,14 @@ pub fn (mut f Fmt) or_expr(or_block ast.OrExpr) {
|
||||||
match or_block.kind {
|
match or_block.kind {
|
||||||
.absent {}
|
.absent {}
|
||||||
.block {
|
.block {
|
||||||
|
if or_block.stmts.len == 0 {
|
||||||
|
f.write(' or { }')
|
||||||
|
} else {
|
||||||
f.writeln(' or {')
|
f.writeln(' or {')
|
||||||
f.stmts(or_block.stmts)
|
f.stmts(or_block.stmts)
|
||||||
f.write('}')
|
f.write('}')
|
||||||
}
|
}
|
||||||
|
}
|
||||||
.propagate {
|
.propagate {
|
||||||
f.write('?')
|
f.write('?')
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue