Overview
| Artifact ID: | f8efa3897e5c2e790e7ca95e646869a6d1e811b0 |
|---|---|
| Ticket: | 218060ffffffffffffffffffffffffffffffffff
info commands return value altered by execution of command i |
| User & Date: | nobody on 2000-10-26 00:52:41 |
Changes
- assignee changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
OriginalBugID: 1507 Bug Version: 8.0.3 SubmitDate: '1999-03-15' LastModified: '1999-11-10' Severity: SER Status: Closed Submitter: pat ChangedBy: hobbs OS: Windows NT OSVersion: 4.0 SP4 Machine: X86 FixedDate: '2000-10-25' ClosedDate: '1999-11-10' Name: Bruce Adams ReproducibleScript: proc putList { channel list { entryFormat "%s" } } { foreach item $list { puts $channel [ format $entryFormat $item ] } } # End Proc putList namespace eval fred { } puts "===========" rename info ::fred::info_builtin proc info { subcommand args } { return [eval ::fred::info_builtin $subcommand $args] } puts "BEFORE:" putList stdout "[ info commands inf* ]" proc info { subcommand args } { # each of the following has the same effect return [namespace eval ::fred info_builtin $subcommand $args] #return [namespace eval ::fred ::fred::info_builtin $subcommand $args] #return [namespace inscope ::fred ::fred::info_builtin $subcommand $args] } puts "AFTER:" putList stdout "[ info commands inf* ]" info_builtin ObservedBehavior: info_builtin is wrongly reported as existing in the global namespace by [ info commands inf* ] when it does not exist. i.e. info info_builtin DesiredBehavior: info commands inf* should only return "info" in the above script This behaviour impacts the development of my introspection package which amongst other things extends the semantics of info, through redefining it and creating a wrapper. -- This is actually the correct behavior. You are evaluating the info command now in the ::fred namespace, which means that it will pick up its new self as info_builtin. Add the procs ::fred::inf ::fred::inf1 ... and you will see them all. -- 11/10/1999 hobbs - foundin changed to: "obsolete: 8.0.3"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "nobody"
- subsystem changed to: "69. Other"
- title changed to:
info commands return value altered by execution of command i
- type changed to: "Bug"