Closed
Description
Tuple desctructuring does not work with underscores if used outside of var
section. Inside it it's OK, and that's confusing. It seems Nim sees _
as a special identifier that should be declared.
Example
var x = 0
(x, _) = (1, 2)
Current Output
Error: undeclared identifier: '_'
Expected Output
To work the same way as
var (x, _) = (1, 2)
(This was fixed at some stage, e.g. bug #2421)
Possible Solution
Additional Information
Checked with Nim 1.4 and Nim 1.5 devel.
Metadata
Metadata
Assignees
Labels
No labels