Artifacts Associated With Ticket 786187ffffffffffffffffffffffffffffffffff
Ticket change [ac60cb8bdb] (rid 101279) by muonics on 2003-08-10 08:31:48:
- assignee initialized to: "msofer"
- cmimetype initialized to: "text/plain"
- comment initialized to:
I found this comment in TclRenameCommand while poking through the sources, which made me curious: "Make sure that the destination command does not already exist. The rename operation is like creating a command, so we should automatically create the containing namespaces just like Tcl_CreateCommand would." I found this interesting, because I often wind up doing an namespace eval "" just to make a namespace exist because I don't usually define my procs within the eval. So I ran a test: % namespace children :: ::tcl % proc ns::test {} {} can't create procedure "ns::test": unknown namespace % proc test {} {} % rename test ns::test % namespace children :: ::ns ::tcl Shouldn't proc be able to do the same? It would be quite handy. - foundin initialized to: "None"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "muonics"
- subsystem initialized to: "22. [proc] and [uplevel]"
- title initialized to:
proc requires a namespace to exist but rename doesn't
- type initialized to: "Bug"
Ticket change [67132dd58d] (rid 102839) by muonics on 2003-08-10 16:07:10:
- icomment:
Logged In: YES user_id=498198 For that matter, how about set and array set? I suppose it might be harder to catch typos in namespace qualifiers, or broken order of initialization, but it might simplify other things a little bit.
- login: "muonics"
- mimetype: "text/plain"
- username: "muonics"
- icomment:
Ticket change [1e1a3eee24] (rid 90919) by msofer on 2003-08-10 21:44:08:
- closedate changed to: "2003-08-10T14:44:08"
- closer changed to: "msofer"
- icomment:
Logged In: YES user_id=148712 In the same spirit as [FR 582926], where the beef starts with automatic namespace creation for [set] and [upvar] and ends requesting ... whenever a "namespace does not exist" error message is currently being returned, instead have the required namespace created automatically I tend to agree it is a bug, and the docs do not really talk about the issue. However, this being very longstanding behaviour (since 8.0) I'm hesitant to fix it within a minor release. Maybe it should be TIPped? In any case, closing as a duplicate and incorporating the example into [FR 582926] seems reasonable.
- login: "msofer"
- mimetype: "text/plain"
- resolution changed to: "Duplicate"
- status changed to: "Closed"
- subsystem changed to: "21. [namespace]"
- username: "msofer"