From aba0bb5e01d467cca60abaa382a14229dd26cc81 Mon Sep 17 00:00:00 2001 From: Joe Conigliaro Date: Thu, 27 Feb 2020 21:15:30 +1100 Subject: [PATCH] v2: fix condition in AssignStmt --- vlib/v/parser/parser.v | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vlib/v/parser/parser.v b/vlib/v/parser/parser.v index 281e6b1128..1bc2c7172d 100644 --- a/vlib/v/parser/parser.v +++ b/vlib/v/parser/parser.v @@ -1527,7 +1527,7 @@ pub fn (p mut Parser) assign_stmt() ast.AssignStmt { expr,_ := p.expr(0) is_decl := op == .decl_assign for ident in idents { - if is_decl && ident.kind == .blank_ident { + if is_decl && ident.kind != .blank_ident { if p.scope.known_var(ident.name) { p.error('redefinition of `$ident.name`') }