#610 compiled foreach does not set non-local variables

obsolete: 8.0p2
closed-fixed
nobody
2
2000-10-26
2000-10-26
Anonymous
No

OriginalBugID: 665 Bug
Version: 8.0p2
SubmitDate: '1998-06-17'
LastModified: '1999-04-16'
Severity: CRIT
Status: Released
Submitter: stanton
ChangedBy: stanton
OS: All
OSVersion: NA
Machine: NA
FixedDate: '1999-04-16'
FixedInVersion: 8.1b3
ClosedDate: '2000-10-25'

The following script behaves differently inside a procedure:

foreach {::foo::a} {1 2} {}

At the global scope, it correctly sets the namespace variable. In a procedure, it creates a local variable named ::foo::a.

Discussion

  • Brent B. Welch
    Brent B. Welch
    2000-10-26

    • priority: 5 --> 2
    • status: open --> closed-fixed