mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
cgen: fix indent in multi_return (#5617)
This commit is contained in:
parent
e904732554
commit
c21527d3c6
@ -2473,7 +2473,7 @@ fn (mut g Gen) return_statement(node ast.Return) {
|
|||||||
g.expr(expr)
|
g.expr(expr)
|
||||||
arg_idx++
|
arg_idx++
|
||||||
if i < node.exprs.len - 1 {
|
if i < node.exprs.len - 1 {
|
||||||
g.write(',')
|
g.write(', ')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
g.write('}')
|
g.write('}')
|
||||||
@ -2482,7 +2482,9 @@ fn (mut g Gen) return_statement(node ast.Return) {
|
|||||||
g.write('return $opt_tmp')
|
g.write('return $opt_tmp')
|
||||||
}
|
}
|
||||||
// Make sure to add our unpacks
|
// Make sure to add our unpacks
|
||||||
g.insert_before_stmt(multi_unpack)
|
if multi_unpack.len > 0 {
|
||||||
|
g.insert_before_stmt(multi_unpack)
|
||||||
|
}
|
||||||
} else if node.exprs.len >= 1 {
|
} else if node.exprs.len >= 1 {
|
||||||
// normal return
|
// normal return
|
||||||
return_sym := g.table.get_type_symbol(node.types[0])
|
return_sym := g.table.get_type_symbol(node.types[0])
|
||||||
|
Loading…
Reference in New Issue
Block a user