mes: compatibility: Make base.mes pure guile.

* mes/module/mes/type-0.mes (procedure?): New function.  Rewrite
without `cond' from
* mes/module/mes/base.mes (procedure?): here; Remove.
This commit is contained in:
Jan (janneke) Nieuwenhuizen 2020-11-01 16:09:27 +01:00
parent 7a6505be6e
commit c30da3435f
No known key found for this signature in database
GPG key ID: F3C1A0D9C1D65273
2 changed files with 6 additions and 6 deletions

View file

@ -119,12 +119,6 @@
(define else #t)
(define (procedure? p)
(cond ((builtin? p) #t)
((and (pair? p) (eq? (car p) 'lambda)))
((closure? p) #t)
(#t #f)))
(define (map f h . t)
(if (or (null? h)
(and (pair? t) (null? (car t)))

View file

@ -76,6 +76,12 @@
(define (port? x)
(eq? (core:type x) <cell:port>))
(define (procedure? p)
(and (or (builtin? p)
(and (pair? p) (eq? (car p) 'lambda))
(closure? p))
#t))
(define (special? x)
(eq? (core:type x) <cell:special>))