From 81641a224004107240a3c7bb4e24b66bf92afb73 Mon Sep 17 00:00:00 2001 From: JeffBezanson Date: Wed, 15 Apr 2009 00:30:24 +0000 Subject: [PATCH] fixing glaring bug in last revision --- femtolisp/flisp.c | 2 ++ femtolisp/system.lsp | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/femtolisp/flisp.c b/femtolisp/flisp.c index 0170ee5..9b96b6b 100644 --- a/femtolisp/flisp.c +++ b/femtolisp/flisp.c @@ -1563,6 +1563,7 @@ static value_t apply_cl(uint32_t nargs) Stack[bp+i+1] = Stack[bp+nargs]; Stack[bp+i+2] = Stack[bp+nargs+1]; Stack[bp+i+3] = Stack[bp+nargs+2]; + pvals = &Stack[bp+nargs+2]; } else { PUSH(NIL); @@ -1570,6 +1571,7 @@ static value_t apply_cl(uint32_t nargs) Stack[SP-2] = Stack[SP-3]; Stack[SP-3] = Stack[SP-4]; Stack[SP-4] = NIL; + pvals = &Stack[SP-1]; } nargs = i+1; break; diff --git a/femtolisp/system.lsp b/femtolisp/system.lsp index d3e183b..3cb9683 100644 --- a/femtolisp/system.lsp +++ b/femtolisp/system.lsp @@ -643,7 +643,8 @@ (define (expand x) (macroexpand x)) -(define (load-process x) (eval (expand x))) +(if (not (bound? 'load-process)) + (define (load-process x) (eval (expand x)))) (define (load filename) (let ((F (file filename :read)))