summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorMiguel Sofer <miguel.sofer@gmail.com>2008-01-16 14:27:43 (GMT)
committerMiguel Sofer <miguel.sofer@gmail.com>2008-01-16 14:27:43 (GMT)
commit90cf37f28b485d5cfdf799b2ead8bf7e1d57b479 (patch)
tree4b74cc78222e0017486148233fde782326a39145 /doc
parent6c2c0eb2c6789725d397ab0f1faf818495fd8207 (diff)
downloadtcl-90cf37f28b485d5cfdf799b2ead8bf7e1d57b479.zip
tcl-90cf37f28b485d5cfdf799b2ead8bf7e1d57b479.tar.gz
tcl-90cf37f28b485d5cfdf799b2ead8bf7e1d57b479.tar.bz2
* doc/proc.n: changed wording for access to non-local variables;
added mention to [namespace upvar]. Lame attempt at dealing with documentation [Bug 1872708]
Diffstat (limited to 'doc')
-rw-r--r--doc/proc.n9
1 files changed, 4 insertions, 5 deletions
diff --git a/doc/proc.n b/doc/proc.n
index b48c623..6bccf28 100644
--- a/doc/proc.n
+++ b/doc/proc.n
@@ -5,7 +5,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: proc.n,v 1.8 2007/12/13 15:22:33 dgp Exp $
+'\" RCS: @(#) $Id: proc.n,v 1.9 2008/01/16 14:27:43 msofer Exp $
'\"
.so man.macros
.TH proc n "" Tcl "Tcl Built-In Commands"
@@ -41,6 +41,7 @@ When \fIname\fR is invoked a local variable
will be created for each of the formal arguments to the procedure; its
value will be the value of corresponding argument in the invoking command
or the argument's default value.
+Actual arguments are assigned to formal arguments strictly in order.
Arguments with default values need not be
specified in a procedure invocation. However, there must be enough
actual arguments for all the
@@ -57,10 +58,8 @@ When \fIbody\fR is being executed, variable names normally refer to
local variables, which are created automatically when referenced and
deleted when the procedure returns. One local variable is automatically
created for each of the procedure's arguments.
-Global variables can only be accessed by invoking
-the \fBglobal\fR command or the \fBupvar\fR command.
-Namespace variables can only be accessed by invoking
-the \fBvariable\fR command or the \fBupvar\fR command.
+Other variables can only be accessed by invoking one of the \fBglobal\fR,
+\fBvariable\fR, \fBupvar\fR or \fBnamespace upvar\fR commands.
.PP
The \fBproc\fR command returns an empty string. When a procedure is
invoked, the procedure's return value is the value specified in a