x-engine-c v0.2.13
The C engine for x-lang
Loading...
Searching...
No Matches
Error Handler Macros

Navigate the error handler pair tree (jmp-ptr (saved-env . previous) error-value . line). A guard's handler carries the handler it displaced in the previous slot, so every installed handler stays reachable from the error_handler slot while the innermost is; a base-eval handler leaves it nil and is consed onto the target's stack. More...

Macros

#define x_error_handler_jmp(H)   x_ptrval(x_firstobj(H))
 
#define x_error_handler_saved_env(H)   x_001(H)
 
#define x_error_handler_error(H)   x_011(H)
 
#define x_error_handler_line(H)   x_111(H)
 

Detailed Description

Navigate the error handler pair tree (jmp-ptr (saved-env . previous) error-value . line). A guard's handler carries the handler it displaced in the previous slot, so every installed handler stays reachable from the error_handler slot while the innermost is; a base-eval handler leaves it nil and is consed onto the target's stack.

Macro Definition Documentation

◆ x_error_handler_error

#define x_error_handler_error (   H)    x_011(H)

◆ x_error_handler_jmp

#define x_error_handler_jmp (   H)    x_ptrval(x_firstobj(H))

◆ x_error_handler_line

#define x_error_handler_line (   H)    x_111(H)

◆ x_error_handler_saved_env

#define x_error_handler_saved_env (   H)    x_001(H)