Added 'depth' counter to stack frames. The idea is two-fold:
1. You can limit runaway recursion by binding a symbol *max_stack_depth* in the environment 2. You can limit the number of backtrace frames printed. However, neither of these have been implemented yet.
This commit is contained in:
parent
72a8bc09e0
commit
2536e76617
7 changed files with 140 additions and 79 deletions
|
|
@ -190,6 +190,10 @@ struct cons_pointer lisp_cond( struct stack_frame *frame,
|
|||
struct cons_pointer frame_pointer,
|
||||
struct cons_pointer env );
|
||||
|
||||
struct cons_pointer throw_exception_with_cause( struct cons_pointer location,
|
||||
struct cons_pointer message,
|
||||
struct cons_pointer cause,
|
||||
struct cons_pointer frame_pointer );
|
||||
/**
|
||||
* Throw an exception.
|
||||
* `throw_exception` is a misnomer, because it doesn't obey the calling
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue