impc:ti:descending-generic-type-match   scheme


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/runtime/llvmti.xtm

Implementation

(define impc:ti:descending-generic-type-match
  (lambda (a b)
    (cond ((equal? a b) #t)
          ((atom? a)
           (if (and (symbol? a)
                    (regex:match? (symbol->string a) "^!"))
               #t
               #f))
          ((atom? b)
           (if (and (symbol? b)
                    (regex:match? (symbol->string b) "^!"))
               #t
               #f))
          (else
           (if (member #f
                       (map (lambda (x y)
                              (impc:ti:descending-generic-type-match x y))
                            a b))
               #f #t)))))


Back to Index