mini-mes: Fix for assq.

* scaffold/mini-mes.c (assq): Use eq_p iso ==.  Fixes
  tests/display.test ("write alarm").
This commit is contained in:
Jan Nieuwenhuizen 2017-04-02 13:18:22 +02:00
parent f79adb637f
commit 81999fbf28

View file

@ -574,9 +574,9 @@ call (SCM fn, SCM x)
SCM
assq (SCM x, SCM a)
{
//FIXME: eq_p
//while (a != cell_nil && eq_p (x, CAAR (a)) == cell_f) a = CDR (a);
while (a != cell_nil && x != CAAR (a)) a = CDR (a);
//FIXME: move into fast-non eq_p-ing assq core:assq?
//while (a != cell_nil && x != CAAR (a)) a = CDR (a);
while (a != cell_nil && eq_p (x, CAAR (a)) == cell_f) a = CDR (a);
return a != cell_nil ? car (a) : cell_f;
}