AllowExc(3tcl)

AllowExc3tcl

Allow all exceptions in next script evaluation

Usage

#include <tcl.h>

Tcl_AllowExceptions(interp)

    


    

Arguments

Tcl_Interp *interp (in)

Interpreter in which script will be evaluated.


    


            

Overview

If a script is evaluated at top-level (i.e. no other scripts are pending evaluation when the script is invoked), and if the script terminates with a completion code other than TCL_OK, TCL_CONTINUE or TCL_RETURN, then Tcl normally converts this into a TCL_ERROR return with an appropriate message.

However, if Tcl_AllowExceptions is invoked immediately before calling a procedure such as Tcl_Eval, then arbitrary completion codes are permitted from the script, and they are returned without modification. This is useful in cases where the caller can deal with exceptions such as TCL_BREAK or TCL_CONTINUE in a meaningful way.

Keywords

continue, break, exception, interpreter

Releases

10 releases since Debian 1.1 (Buzz); the text changed 3 times.

  1. 1.1–2.1
  2. 2.2–3.0
  3. 3.1–4.0
  4. 5.0

From tcl8.3-doc 8.3.5-13 in Debian 5.0 (Lenny). Parsed by carta from the page's man source.