diff options
author | dgp <dgp@noemail.net> | 2013-07-12 16:25:51 (GMT) |
---|---|---|
committer | dgp <dgp@noemail.net> | 2013-07-12 16:25:51 (GMT) |
commit | bbdfac27d5d81cc4970574596e5d2a6bd7e7f51c (patch) | |
tree | b1455b87599b731716eba042fb8101de4fdbcb67 /tests/info.test | |
parent | 0610188c28053b302868025029890fe0b286bd6e (diff) | |
download | tcl-bbdfac27d5d81cc4970574596e5d2a6bd7e7f51c.zip tcl-bbdfac27d5d81cc4970574596e5d2a6bd7e7f51c.tar.gz tcl-bbdfac27d5d81cc4970574596e5d2a6bd7e7f51c.tar.bz2 |
Tests demonstrating the need for the last two SetLineInformation() calls.
FossilOrigin-Name: 4b58b335d45540931d29e456d463046d88cc92b4
Diffstat (limited to 'tests/info.test')
-rw-r--r-- | tests/info.test | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/tests/info.test b/tests/info.test index afdaaee..3057dd2 100644 --- a/tests/info.test +++ b/tests/info.test @@ -2371,6 +2371,31 @@ test info-33.33 {{*}, literal, simple, bytecompiled} -body { } -result {type source line 2365 file info.test cmd {info frame 0} proc ::foo::bar level 0} # ------------------------------------------------------------------------- +namespace eval foo {} +proc foo::bar {} { + append x {*}{ + } [return [info frame 0]] +} +test info-33.34 {{*}, literal, simple, bytecompiled} -body { + reduce [foo::bar] +} -cleanup { + namespace delete foo +} -result {type source line 2377 file info.test cmd {info frame 0} proc ::foo::bar level 0} + +# ------------------------------------------------------------------------- +namespace eval foo {} +proc foo::bar {} { + append {*}{ + } x([return [info frame 0]]) {*}{ + } a +} +test info-33.35 {{*}, literal, simple, bytecompiled} -body { + reduce [foo::bar] +} -cleanup { + namespace delete foo +} -result {type source line 2389 file info.test cmd {info frame 0} proc ::foo::bar level 0} + +# ------------------------------------------------------------------------- unset -nocomplain res # cleanup |