1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

parser: add additional paren for multi case branch

This commit is contained in:
Danil-Lapirow 2019-09-04 19:47:37 +03:00 committed by Alexander Medvednikov
parent dd670fb4a3
commit 5c43bfbf13

View File

@ -3474,6 +3474,9 @@ fn (p mut Parser) match_statement(is_expr bool) string {
p.expected_type = ''
if p.tok != .comma {
if got_comma {
p.gen(') ')
}
break
}
p.check(.comma)