fixes #14498 [backport:1.2] (#14503)

This commit is contained in:
Andreas Rumpf 2020-05-30 15:32:31 +02:00 • committed by GitHub
commit 7ccc7d7e93
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 26 additions and 6 deletions

View file

@ -0,0 +1,14 @@
discard """
errmsg: "'x' cannot be assigned to"
line: 10
"""
proc bug14498 =
var a = @['a', 'b', 'c', 'd', 'e', 'f']
for x in a:
x = 'c'
echo a
bug14498()