mirror of
https://github.com/vlang/v.git
synced 2025-09-16 16:02:29 +03:00
use ++ everywhere
This commit is contained in:
parent
cc682eafe1
commit
c9886e6f42
8 changed files with 17 additions and 16 deletions
|
@ -1386,8 +1386,8 @@ fn ($v.name mut $v.typ) $p.cur_fn.name (...) {
|
|||
}
|
||||
else {
|
||||
next := p.peek_token()
|
||||
if next.tok == .number && next.lit== '1' {
|
||||
p.warn('use ++ instead of += 1')
|
||||
if next.tok == .number && next.lit== '1' {
|
||||
p.error('use `++` instead of `+= 1`')
|
||||
}
|
||||
p.gen(' += ')
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue