diff options
author | dgp <dgp@users.sourceforge.net> | 2013-09-19 14:56:29 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2013-09-19 14:56:29 (GMT) |
commit | 81c1f15aff0ed7ab5c3e6ff85071787619f7ed45 (patch) | |
tree | 8d68ad1e18857ac0347c279d4886c606de6473e2 | |
parent | b6c1b41e104b590889abc40a5b8cab1436d2e52c (diff) | |
parent | 58c74e141ff1c65580defe7237e86826b15afea2 (diff) | |
download | tcl-81c1f15aff0ed7ab5c3e6ff85071787619f7ed45.zip tcl-81c1f15aff0ed7ab5c3e6ff85071787619f7ed45.tar.gz tcl-81c1f15aff0ed7ab5c3e6ff85071787619f7ed45.tar.bz2 |
Line numbers wrong in compiled [dict for].
-rw-r--r-- | generic/tclCompCmds.c | 2 | ||||
-rw-r--r-- | tests/dict.test | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/generic/tclCompCmds.c b/generic/tclCompCmds.c index 8f72367..45e856f 100644 --- a/generic/tclCompCmds.c +++ b/generic/tclCompCmds.c @@ -1424,7 +1424,7 @@ CompileDictEachCmd( * this point. */ - CompileWord(envPtr, dictTokenPtr, interp, 3); + CompileWord(envPtr, dictTokenPtr, interp, 2); /* * Now we catch errors from here on so that we can finalize the search diff --git a/tests/dict.test b/tests/dict.test index 3d86668..f8d62f1 100644 --- a/tests/dict.test +++ b/tests/dict.test @@ -1887,6 +1887,12 @@ test dict-23.6 {CompileWord OBOE} { } [return [incr n -[linenumber]]] }} [linenumber] } 1 +test dict-23.7 {CompileWord OBOE} { + apply {n { + dict for {a b} [return [incr n -[linenumber]]] {*}{ + } {} + }} [linenumber] +} 2 rename linenumber {} test dict-24.22 {dict map results (non-compiled)} { |