Tcl Expert · Lesson 7

Errors as data: throw, -errorcode, try trap and return -options

Raise errors that code can classify, catch them by error code, always run clean-up, and re-raise errors without losing their details.

Lessons · Tcl Expert · Lesson 7 of 10

Errors as data: throw, -errorcode, try trap and return -options

Raise errors that code can classify, catch them by error code, always run clean-up, and re-raise errors without losing their details.

Illustration for Tcl
Raise errors that code can classify, catch them by error code, always run clean-up, and re-raise errors without losing their details.