mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
parser: fix multi return with multiple blank identifiers
This commit is contained in:
parent
282cd44cec
commit
8fe0e88c05
@ -1437,8 +1437,10 @@ fn (p mut Parser) var_decl() {
|
|||||||
}
|
}
|
||||||
for i, name in names {
|
for i, name in names {
|
||||||
var_token_idx := vtoken_idxs[i]
|
var_token_idx := vtoken_idxs[i]
|
||||||
if name == '_' && names.len == 1 {
|
if name == '_' {
|
||||||
p.error_with_token_index('no new variables on left side of `:=`', var_token_idx)
|
if names.len == 1 {
|
||||||
|
p.error_with_token_index('no new variables on left side of `:=`', var_token_idx)
|
||||||
|
}
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
typ := types[i]
|
typ := types[i]
|
||||||
|
Loading…
Reference in New Issue
Block a user