summaryrefslogtreecommitdiffstats
path: root/doc/uplevel.n
diff options
context:
space:
mode:
Diffstat (limited to 'doc/uplevel.n')
-rw-r--r--doc/uplevel.n13
1 files changed, 5 insertions, 8 deletions
diff --git a/doc/uplevel.n b/doc/uplevel.n
index d34716c..c8ef0ff 100644
--- a/doc/uplevel.n
+++ b/doc/uplevel.n
@@ -14,7 +14,6 @@ uplevel \- Execute a script in a different stack frame
.SH SYNOPSIS
\fBuplevel \fR?\fIlevel\fR?\fI arg \fR?\fIarg ...\fR?
.BE
-
.SH DESCRIPTION
.PP
All of the \fIarg\fR arguments are concatenated as if they had
@@ -53,16 +52,16 @@ the command
.CE
then the \fBset\fR command will modify the same variable \fBx\fR in \fBb\fR's
context: the procedure \fBc\fR does not appear to be on the call stack
-when \fBd\fR is executing. The command ``\fBinfo level\fR'' may
+when \fBd\fR is executing. The \fBinfo level\fR command may
be used to obtain the level of the current procedure.
.PP
\fBUplevel\fR makes it possible to implement new control
constructs as Tcl procedures (for example, \fBuplevel\fR could
be used to implement the \fBwhile\fR construct as a Tcl procedure).
.PP
-\fBnamespace eval\fR is another way (besides procedure calls)
-that the Tcl naming context can change.
-It adds a call frame to the stack to represent the namespace context.
+The \fBnamespace eval\fR and \fBapply\fR commands offer other ways
+(besides procedure calls) that the Tcl naming context can change.
+They add a call frame to the stack to represent the namespace context.
This means each \fBnamespace eval\fR command
counts as another call level for \fBuplevel\fR and \fBupvar\fR commands.
For example, \fBinfo level 1\fR will return a list
@@ -90,9 +89,7 @@ proc do {body while condition} {
}
}
.CE
-
.SH "SEE ALSO"
-namespace(n), upvar(n)
-
+apply(n), namespace(n), upvar(n)
.SH KEYWORDS
context, level, namespace, stack frame, variables