Artifacts Associated With Ticket 1768830
Ticket change [8746d191af] (rid 131667) by nobody on 2007-08-06 21:26:48:
- assignee initialized to: "msofer"
- cmimetype initialized to: "text/plain"
- comment initialized to:
The following is taken from the online description of the "upvar" command which was generated from Tcl CVS HEAD. SYNOPSIS upvar ?level? otherVar myVar ?otherVar myVar ...? DESCRIPTION The variable named by otherVar need not exist at the time of the call; it will be created the first time myVar is referenced, just like an ordinary variable. The statement that "otherVar" will be created in case of a call to "myVar" is confusing and probably wrong. In case of a call to "myVar" or if used the first time and if the referenced "otherVar" does not exist a error will be raised by the tcl interpreter that "myVar" can't be read because it is not existing. This is because "myVar" references to nothing. The following example will illustrate this with the second procedure call: #!/usr/bin/tclsh proc CallOn { variable } { upvar $variable variableRef puts "variable=$variable" puts "variableRef=$variableRef" } set v "Test" CallOn v ; # by name CallOn $v ; # by value - foundin initialized to: "obsolete: 8.5a7"
- is_private initialized to: "0"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "nobody"
- subsystem initialized to: "07. Variables"
- title initialized to: "Documentation of "upvar" command"
- type initialized to: "Bug"
Ticket change [ac870bc3c0] (rid 101313) by msofer on 2007-08-07 04:47:27:
- closedate changed to: "2007-08-06T21:47:27"
- closer changed to: "msofer"
- icomment:
Logged In: YES user_id=148712 Originator: NO User confusion: the variable exists but is undefined, its value cannot be retrieved until it has one.
- login: "msofer"
- mimetype: "text/plain"
- resolution changed to: "Invalid"
- status changed to: "Closed"
- username: "msofer"