diff options
author | ferrieux <ferrieux@noemail.net> | 2010-10-17 20:16:55 (GMT) |
---|---|---|
committer | ferrieux <ferrieux@noemail.net> | 2010-10-17 20:16:55 (GMT) |
commit | c26427234a2726152eb15dfb2e550f0c19576ffc (patch) | |
tree | 4afecd576180ca43811d209aeacdc378a6231e49 /doc | |
parent | 90eafcc89625829909ffed53a838f3a3d297f34a (diff) | |
download | tcl-c26427234a2726152eb15dfb2e550f0c19576ffc.zip tcl-c26427234a2726152eb15dfb2e550f0c19576ffc.tar.gz tcl-c26427234a2726152eb15dfb2e550f0c19576ffc.tar.bz2 |
Document [info errostack] faithfully.
FossilOrigin-Name: 997462044d4f903d617d02efdade5c4a521802ff
Diffstat (limited to 'doc')
-rw-r--r-- | doc/info.n | 18 |
1 files changed, 14 insertions, 4 deletions
@@ -8,7 +8,7 @@ '\" 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 $ +'\" RCS: @(#) $Id: info.n,v 1.39 2010/10/17 20:16:55 ferrieux Exp $ '\" .so man.macros .TH info n 8.4 Tcl "Tcl Built-In Commands" @@ -96,9 +96,19 @@ 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 +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. |