* fix #15972

* add testcase

* more
This commit is contained in:
flywind 2020-11-18 08:14:14 +08:00 • committed by GitHub
commit 0869d2a477
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 34 additions and 2 deletions

View file

@ -0,0 +1,16 @@
discard """
errormsg: "undeclared identifier: '_'"
"""
iterator iter(): (int, int) =
yield (1, 2)
yield (3, 4)
yield (1, 2)
yield (3, 4)
yield (1, 2)
yield (3, 4)
for (_, i) in iter():
echo _