p:predicate   scheme


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/base/pattern.xtm

Implementation

;;@ignore
;; Matches an element iff a predicate holds for that element.
(define (p:predicate predicate?)
  (matcher:make 'single
                (lambda (datum sofar success)
                  (if (predicate? datum)
                      (success sofar)
                      #f))))


Back to Index

Similar Entries