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

Re: Confusion about deftype and CLOS classes.



> Date: Fri, 14 Jun 91 00:33:52 EDT
> From: Peter Szolovits <psz@lcs.mit.edu>
> Do I need to do something ugly
> like
> 
> (deftype bar () (integer 0 *))
> (setf (find-class 'bar-class) (find-class 'integer))
> (defmethod zorch ((x bar-class))
>   (when (typep x 'bar) ...))

Yes.

The committee that defined CLOS didn't want to provide for method
selection on types more general than classes, since that would have
raised a number of awkward issues.