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

Re: managing a resource of instances

I think this is a good reason why programs should provide their own constructors
instead of using MAKE-INSTANCE as their public interface to object creation.  If
you defined your own MAKE-FONT function, you could accomplish exactly what you

(defun MAKE-FONT (&rest initargs)
  (or (FIND-FONT initargs)
      (CACHE-FONT (apply #'MAKE-INSTANCE 'font initargs)

----- smL