mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-20 11:40:18 +02:00
fix bug in memoize
* libguile/memoize.c (memoize): Fix a bug where LETREC was being accessed as LET, and it just happened to coincide.
This commit is contained in:
parent
89cdf5a379
commit
f238862e9e
1 changed files with 3 additions and 3 deletions
|
@ -377,9 +377,9 @@ memoize (SCM exp, SCM env)
|
||||||
SCM vars, exps, body, undefs, inits, sets, new_env;
|
SCM vars, exps, body, undefs, inits, sets, new_env;
|
||||||
int i, nvars;
|
int i, nvars;
|
||||||
|
|
||||||
vars = REF (exp, LET, GENSYMS);
|
vars = REF (exp, LETREC, GENSYMS);
|
||||||
exps = REF (exp, LET, VALS);
|
exps = REF (exp, LETREC, VALS);
|
||||||
body = REF (exp, LET, BODY);
|
body = REF (exp, LETREC, BODY);
|
||||||
nvars = i = scm_ilength (vars);
|
nvars = i = scm_ilength (vars);
|
||||||
inits = undefs = sets = SCM_EOL;
|
inits = undefs = sets = SCM_EOL;
|
||||||
new_env = env;
|
new_env = env;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue