diff options
author | Keith Packard <keithp@keithp.com> | 2017-12-01 15:40:23 -0600 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2017-12-01 15:40:23 -0600 |
commit | c31744299e5a4342bbe26d3735ee2d8f09192ae9 (patch) | |
tree | 108153f1d01c56800d6e4dc0c56dbcce979717be /src/lisp/ao_lisp_eval.c | |
parent | 98923ae1189f062b8b94120d47a56892db25493f (diff) |
altos/lisp: split set/def. Add def support to lambdas
In scheme, set can only re-define existing variables while def cannot
redefine existing variables in lambda context. Def within lambda
creates a new variable at the nearest enclosing scope.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/lisp/ao_lisp_eval.c')
-rw-r--r-- | src/lisp/ao_lisp_eval.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lisp/ao_lisp_eval.c b/src/lisp/ao_lisp_eval.c index fa25edf0..02329ee6 100644 --- a/src/lisp/ao_lisp_eval.c +++ b/src/lisp/ao_lisp_eval.c @@ -559,6 +559,8 @@ ao_lisp_eval(ao_poly _v) { ao_lisp_v = _v; + ao_lisp_frame_init(); + if (!ao_lisp_stack_push()) return AO_LISP_NIL; |