chickadee » operations » define-predicate

(define-predicate variable)syntax

Returns: undefined

Defines variable to be an operation which, by default, returns false.

 (define-predicate var) 
   ==>
 (define-operation (var obj) #f)

The intent is that particular OBJECT-expressions contain clauses of the form ((variable SELF) #t). This way the operation defined by DEFINE-PREDICATE may act as a type predicate that returns true only for those objects returned by such OBJECT-expressions.