Explorar el Código

implement the quote special form.

that was easy. (if it is correct.)

onwards to list! (which is trickier, because it has a variable number of
arguments and we have to call evalo on all of them, in sequence.
mhh... that kind of sounds like we need a listo?)
Lucas Stadler %!s(int64=11) %!d(string=hace) años
padre
commit
1cb71c4e56
Se han modificado 1 ficheros con 3 adiciones y 0 borrados
  1. 3 0
      scm/evalo.scm

+ 3 - 0
scm/evalo.scm

@ -19,6 +19,9 @@
19 19
    (conde
20 20
     [(symbolo expr)
21 21
      (lookupo expr env val)]
22
     [(fresh (e)
23
        (== `(quote ,e) expr)
24
        (== e val))]
22 25
     [(fresh (x body)
23 26
        (== `(lambda (,x) ,body) expr)
24 27
        (== `(closure ,x ,body ,env) val))]