|
2003-01-22
| ||
| 03:10 | • Closed ticket [670110ffff]: Misleading documentation for namespace inscope... artifact: cf94ab90c1 user: jenglish | |
| 00:35 | • Ticket [670110ffff]: 4 changes artifact: 540f512945 user: dgp | |
|
2003-01-18
| ||
| 09:08 | • Ticket [670110ffff]: 5 changes artifact: e8ff05d420 user: jenglish | |
| 02:05 | • New ticket [670110ffff]. artifact: 0d039c6ac8 user: jenglish | |
Misleading documentation for [namespace inscope]
Closed / Fixed670110ffffffffffffffffffffffffffffffffffCreated 24 years agoUpdated 24 years ago
Descriptionplain2003-01-18 02:05:25
(from discussions on the Tcl'ers Chat, 16 Jan 2002) The documentation for [namespace inscope] is misleading, in that it claims to have "lappend semantics" and "treats the first argument as a list". This is only true under the Tcl 7.X definition of "lappend", not under the 8.X definition.
jenglishplain2003-01-18 09:08:51
Logged In: YES user_id=68433 Here is a proposed rewording. Let me know if this looks OK and I'll commit the change. .TP \fBnamespace inscope\fR \fInamespace\fR \fIscript\fR ?\fIarg ...\fR? Executes a script in the context of the specified \fInamespace\fR. This command is not expected to be used directly by programmers; calls to it are generated implicitly when applications use \fBnamespace code\fR commands to create callback scripts that the applications then register with, e.g., Tk widgets. The \fBnamespace inscope\fR command is much like the \fBnamespace eval\fR command except that the \fInamespace\fR must already exist, and \fBnamespace inscope\fR appends additional \fIarg\fRs as proper list elements. .br \fBnamespace inscope ::foo $script $x $y $z\fR is equivalent to \fBnamespace eval ::foo [concat $script [list $x $y $z]]\fR thus additional arguments will not undergo a second round of substitution, as is the case with \fBnamespace eval\fR. ... Also, the documention for [namespace code] says that it wraps the script in a [namespace code] command; this should say [namespace inscope] instead.
dgpplain2003-01-22 00:35:50
Logged In: YES user_id=80530 that's an improvement. make it so.
jenglishplain2003-01-22 03:10:30
Logged In: YES user_id=68433 Committed patch. (doc/namespace.n r1.9)
Log in (anonymous is fine) to add a comment.