Skip to content

Commit

Permalink
parser: fix incorrect comments of expr() (#8979)
Browse files Browse the repository at this point in the history
  • Loading branch information
yuyi98 committed Feb 26, 2021
1 parent 89c82ff commit 524372d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion vlib/v/parser/pratt.v
Expand Up @@ -76,10 +76,11 @@ pub fn (mut p Parser) expr(precedence int) ast.Expr {
p.next()
}
.amp, .mul, .not, .bit_not, .arrow {
// -1, -a, !x, &x, ~x, <-a
// &x, *x, !x, ~x, <-x
node = p.prefix_expr()
}
.minus {
// -1, -a
if p.peek_tok.kind == .number {
node = p.parse_number_literal()
} else {
Expand Down

0 comments on commit 524372d

Please sign in to comment.