summaryrefslogtreecommitdiffstats
path: root/doc/interp.n
diff options
context:
space:
mode:
Diffstat (limited to 'doc/interp.n')
-rw-r--r--doc/interp.n14
1 files changed, 7 insertions, 7 deletions
diff --git a/doc/interp.n b/doc/interp.n
index a118e50..8b1815a 100644
--- a/doc/interp.n
+++ b/doc/interp.n
@@ -4,7 +4,7 @@
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
-'\" RCS: @(#) $Id: interp.n,v 1.9.2.1 2004/10/27 12:52:40 dkf Exp $
+'\" RCS: @(#) $Id: interp.n,v 1.9.2.2 2004/10/27 14:23:56 dkf Exp $
'\"
.so man.macros
.TH interp n 7.6 Tcl "Tcl Built-In Commands"
@@ -618,23 +618,23 @@ by Nathaniel Borenstein and Marshall Rose.
.SH EXAMPLES
Creating and using an alias for a command in the current interpreter:
.CS
-\fBinterp\fR alias {} getIndex {} lsearch {alpha beta gamma delta}
+\fBinterp alias\fR {} getIndex {} lsearch {alpha beta gamma delta}
set idx [getIndex delta]
.CE
.PP
Executing an arbitrary command in a safe interpreter where every
invokation of \fBlappend\fR is logged:
.CS
-set i [\fBinterp\fR create -safe]
-\fBinterp\fR hide $i lappend
-\fBinterp\fR alias $i lappend {} loggedLappend $i
+set i [\fBinterp create\fR -safe]
+\fBinterp hide\fR $i lappend
+\fBinterp alias\fR $i lappend {} loggedLappend $i
proc loggedLappend {i args} {
puts "logged invokation of lappend $args"
# Be extremely careful about command construction
eval [linsert $args 0 \\
- \fBinterp\fR invokehidden $i lappend]
+ \fBinterp invokehidden\fR $i lappend]
}
-\fBinterp\fR eval $i $someUntrustedScript
+\fBinterp eval\fR $i $someUntrustedScript
.CE
.SH "SEE ALSO"