diff options
author | dgp <dgp@users.sourceforge.net> | 2016-06-16 17:12:45 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2016-06-16 17:12:45 (GMT) |
commit | fe25eaf4025ec9453fb1e239471b9a5a950f6cf6 (patch) | |
tree | 0679e41842789c07c8c6d988f93f8732b049a736 /tests | |
parent | 624ec168ecde5fbdbe83e4e7c558805b408fabcc (diff) | |
parent | ac2ab0075f3bd2da55b9eb003f12455ca981df21 (diff) | |
download | tcl-fe25eaf4025ec9453fb1e239471b9a5a950f6cf6.zip tcl-fe25eaf4025ec9453fb1e239471b9a5a950f6cf6.tar.gz tcl-fe25eaf4025ec9453fb1e239471b9a5a950f6cf6.tar.bz2 |
[4b61afd660] Allow [info frame] to record line info for substituted command names.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/info.test | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/info.test b/tests/info.test index 937da8c..d30bf9a 100644 --- a/tests/info.test +++ b/tests/info.test @@ -1818,6 +1818,23 @@ test info-38.2 {location information for uplevel, dl, direct-literal} -match glo * {type source line 1814 file info.test cmd etrace level 1} * {type source line 1812 file info.test cmd uplevel\\ \\\\ level 1}} -cleanup {interp delete sub} +test info-39.0 {Bug 4b61afd660} -setup { + proc probe {} { + return [dict get [info frame -1] line] + } + set body { + set cmd probe + $cmd + } + proc demo {} $body +} -body { + demo +} -cleanup { + unset -nocomplain body + rename demo {} + rename probe {} +} -result 3 + # cleanup catch {namespace delete test_ns_info1 test_ns_info2} ::tcltest::cleanupTests |