[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

<class>-p function



In PCL of "2/24/87" in CMU CommonLisp I ran into an interesting
feature.  Since I was under the impression that DefClass didn't define
a type predicate and I happened to want one, I defined one as:

(defun <class>-p (object)
  (typep object '<class>))

which is what was recommended in Gregor's mail of 4-Dec-86.
Unfortunately things had already been defined such that evaluating
(typep object '<class>) was equivalent to (<class>-p object) which lead
to an infinite recursion.

So, it appears that DefClass *does* define a predicate (at least in
"2/24/87") and that the recommended approach can be a lose.

			Rick