important use of [info level 0] broken
Closed / Fixed1587618fffffffffffffffffffffffffffffffffCreated 20 years agoUpdated 20 years ago
Descriptionplain2006-10-31 01:05:54
HEAD breaks [info level 0]'s utility to find out the
number of arguments of a call, if the call is performed
via a curry (ensemble, apply or interp alias).
This breaks a very common idiom (used throughout in
tcllib), for instance:
proc ::struct::matrix::MatrixProc {name {cmd ""} args} {
# Do minimal args checks here
if { [llength [info level 0]] == 2 } {
...
[info level 0] should revert to its original behaviour
(true objv of the call).
msoferplain2006-10-31 17:28:05
Logged In: YES user_id=148712 The usage of [info level] in error stack traces, and to create error messages as eg in [clock], led to [FR 1577492 ] "let [info level] know ensemble rewrites" and this modification. ISTM that breaking a common idiom that has no simple workaround is a relatively severe bug, and nicer error messages more like a WIBNI.
dkfplain2006-10-31 20:48:01
Logged In: YES user_id=79902 Fixed in HEAD. We could do with some kind of scheme that allows procedures to find out what they were called as before rewrites, but [info level 0] can't be it. :-\
dkf Ticket [1587618fff]: 4 changes
[History diff]2006-10-31 20:48:02
Log in (anonymous is fine) to add a comment.