1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
'\"
'\" Copyright (c) 1993 The Regents of the University of California.
'\" Copyright (c) 1994-1997 Sun Microsystems, Inc.
'\" Copyright (c) 1993-1997 Bell Labs Innovations for Lucent Technologies
'\" Copyright (c) 1998-2000 Ajuba Solutions
'\" Copyright (c) 2007-2008 Donal K. Fellows
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
'\" RCS: @(#) $Id: info.n,v 1.38 2010/04/07 09:51:31 dkf Exp $
'\"
.so man.macros
.TH info n 8.4 Tcl "Tcl Built-In Commands"
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
info \- Return information about the state of the Tcl interpreter
|
|
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
'\"
'\" Copyright (c) 1993 The Regents of the University of California.
'\" Copyright (c) 1994-1997 Sun Microsystems, Inc.
'\" Copyright (c) 1993-1997 Bell Labs Innovations for Lucent Technologies
'\" Copyright (c) 1998-2000 Ajuba Solutions
'\" Copyright (c) 2007-2008 Donal K. Fellows
'\"
'\" See the file "license.terms" for information on usage and redistribution
'\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
'\"
'\" RCS: @(#) $Id: info.n,v 1.38.2.1 2010/10/20 01:50:18 kennykb Exp $
'\"
.so man.macros
.TH info n 8.4 Tcl "Tcl Built-In Commands"
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
info \- Return information about the state of the Tcl interpreter
|
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
must be the name of an argument to that procedure. If \fIarg\fR
does not have a default value then the command returns \fB0\fR.
Otherwise it returns \fB1\fR and places the default value of \fIarg\fR
into variable \fIvarname\fR.
.TP
\fBinfo errorstack \fR?\fIinterp\fR?
.VS 8.6
Returns a list of lists made of the function names and arguments at each level
from the call stack of the last error in the given \fIinterp\fR, or in the
current one if not specified. This information is also present in the
\fB\-errorstack\fR entry of the options dictionary returned by 3-argument
\fBcatch\fR; \fBinfo errorstack\fR is a convenient way of retrieving it for
uncaught errors at toplevel in an interactive tclsh.
.VE 8.6
.TP
\fBinfo exists \fIvarName\fR
.
|
|
|
>
>
>
>
>
>
>
>
>
>
|
|
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
|
must be the name of an argument to that procedure. If \fIarg\fR
does not have a default value then the command returns \fB0\fR.
Otherwise it returns \fB1\fR and places the default value of \fIarg\fR
into variable \fIvarname\fR.
.TP
\fBinfo errorstack \fR?\fIinterp\fR?
.VS 8.6
Returns, in a form that is programmatically easy to parse, the function names
and arguments at each level from the call stack of the last error in the given
\fIinterp\fR, or in the current one if not specified.
This form is an
even-sized list alternating tokens and parameters. Tokens are currently either
\fBCALL\fR or \fBUP\fR, but other values may be introduced in the
future. \fBCALL\fR indicates a procedure call, and its parameter is the
corresponding [info level 0]; \fBUP\fR indicates a shift in variable frames
generated by uplevel or similar, and applies to the previous CALL item. Its
parameter is the level offset.
This information is also present in the
\fB\-errorstack\fR entry of the options dictionary returned by 3-argument
\fBcatch\fR; \fBinfo errorstack\fR is a convenient way of retrieving it for
uncaught errors at toplevel in an interactive tclsh.
.VE 8.6
.TP
\fBinfo exists \fIvarName\fR
.
|