summaryrefslogtreecommitdiffstats
path: root/doc/upvar.n
diff options
context:
space:
mode:
Diffstat (limited to 'doc/upvar.n')
-rw-r--r--doc/upvar.n12
1 files changed, 6 insertions, 6 deletions
diff --git a/doc/upvar.n b/doc/upvar.n
index 08f053c..02a475d 100644
--- a/doc/upvar.n
+++ b/doc/upvar.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: upvar.n,v 1.20 2010/01/13 12:08:30 dkf Exp $
+'\" RCS: @(#) $Id: upvar.n,v 1.21 2010/01/20 13:42:17 dkf Exp $
'\"
.so man.macros
.TH upvar n "" Tcl "Tcl Built-In Commands"
@@ -48,8 +48,8 @@ For example, consider the following procedure:
.PP
.CS
proc \fIadd2\fR name {
- \fBupvar\fR $name x
- set x [expr {$x + 2}]
+ \fBupvar\fR $name x
+ set x [expr {$x + 2}]
}
.CE
.PP
@@ -90,11 +90,11 @@ rather than
.PP
.CS
proc \fItraceproc\fR { name index op } {
- puts $name
+ puts $name
}
proc \fIsetByUpvar\fR { name value } {
- \fBupvar\fR $name localVar
- set localVar $value
+ \fBupvar\fR $name localVar
+ set localVar $value
}
set originalVar 1
trace variable originalVar w \fItraceproc\fR