From 1efbb830608cdec642edca2e5690aadbf77ec8dd Mon Sep 17 00:00:00 2001 From: yuyi Date: Fri, 3 Jul 2020 17:23:23 +0800 Subject: [PATCH] cgen: add space before `else` in match (#5632) --- vlib/v/gen/cgen.v | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vlib/v/gen/cgen.v b/vlib/v/gen/cgen.v index f856e17a55..84e77cf970 100644 --- a/vlib/v/gen/cgen.v +++ b/vlib/v/gen/cgen.v @@ -2025,7 +2025,7 @@ fn (mut g Gen) match_expr(node ast.MatchExpr) { // TODO too many branches. maybe separate ?: matches g.write(' : ') } else { - g.writeln('else {') + g.writeln(' else {') } } } else { @@ -2033,7 +2033,7 @@ fn (mut g Gen) match_expr(node ast.MatchExpr) { if is_expr { g.write(' : ') } else { - g.write('else ') + g.write(' else ') } } if is_expr {