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

Re: meta-object protocol



I brought up this same issue about a year and a half ago.  What I wanted to
write was:

(defclass my-class (standard-class) ())

(defclass my-object (object)
  ()
  (:metaclass my-class))

(Actually I wanted to add one more slot to MY-CLASS, but I left it out here
to make a point.)  In this example I saw no reason why the super of OBJECT
should be incompatible with MY-OBJECT.  *All* functionality of
STANDARD-CLASS has been inherited into MY-CLASS.

The argument against it then, as I recall, was that subclassing a
meta-class (1) by definition causes an incompatibility between
super-classes that use them (subtrees of the hierarchy must be instances of
the same meta-class) and (2) is only intended for the implementors of new
languages.  Therefore the CHECK-SUPER-METACLASS-COMPATIBILITY method
returns NIL.