Skip to content

Commit

Permalink
parser: cleanup enum_decl() in parser.v (#19701)
Browse files Browse the repository at this point in the history
  • Loading branch information
yuyi98 committed Oct 30, 2023
1 parent 395b55f commit 6609223
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions vlib/v/parser/parser.v
Expand Up @@ -4056,13 +4056,15 @@ fn (mut p Parser) enum_decl() ast.EnumDecl {
enum_attrs[val] = attrs
p.attrs = []
}
comments := p.eat_comments(same_line: true)
next_comments := p.eat_comments()
fields << ast.EnumField{
name: val
pos: pos
expr: expr
has_expr: has_expr
comments: p.eat_comments(same_line: true)
next_comments: p.eat_comments()
comments: comments
next_comments: next_comments
attrs: attrs
}
}
Expand Down

0 comments on commit 6609223

Please sign in to comment.