I've proved this code in another lisp compiler (MCL) and there is no
problem, but in cmucl there is an error.
Please, if somebody can explain to me why this happend here in Cmucl,
I'll apreciate it a lot.

Gerardo M. Sarria M.

----------------------------------------------------------------------


* (defclass omclass (standard-class) ())

#<STANDARD-CLASS OMCLASS {48033EBD}>
* (defclass OMBasicObject () ())

#<STANDARD-CLASS OMBASICOBJECT {4820F6E5}>
* (defclass OMGenericFunction (standard-generic-function OMBasicObject)
()
(:metaclass omclass))


Error in function "DEFMETHOD SHARED-INITIALIZE :AFTER (STD-CLASS T)":
   The class #<Funcallable-Standard-Class STANDARD-GENERIC-FUNCTION
               {28162975}> was specified as a

                     super-class of the class #<Omclass
OMGENERICFUNCTION {48217B9D}>;
but the meta-classes #<Standard-Class PCL:FUNCALLABLE-STANDARD-CLASS
                       {281631A5}> and
#<Standard-Class OMCLASS {4801BB65}> are incompatible.
Define a method for PCL:VALIDATE-SUPERCLASS to avoid this error.

Restarts:
  0: [ABORT] Return to Top-Level.

Debug  (type H for help)

("DEFMETHOD SHARED-INITIALIZE :AFTER (STD-CLASS T)" (#(NIL 16 6 3) .
#())
 #<unused-arg> #<Omclass OMGENERICFUNCTION {48217B9D}> #<unused-arg>
...)
Source: Error finding source:
Error in function DEBUG::GET-FILE-TOP-LEVEL-FORM:  Source file no longer
exists:
  target:pcl/std-class.lisp.
0] backtrace

0: ("DEFMETHOD SHARED-INITIALIZE :AFTER (STD-CLASS T)" (#(NIL 16 6 3) .
#())
    #<unused-arg> #<Omclass OMGENERICFUNCTION {48217B9D}> #<unused-arg>
...)
1: ("PRECOMPILE-RANDOM-CODE-SEGMENTS PCL" #<unused-arg> #<unused-arg>
    #<Omclass OMGENERICFUNCTION {48217B9D}> T ...)
2: ("DEFMETHOD MAKE-INSTANCE (CLASS)" #<unused-arg> #<unused-arg>
    #<Standard-Class OMCLASS {4801BB65}>
    (:NAME OMGENERICFUNCTION :DIRECT-SUPERCLASSES (# #) :DIRECT-SLOTS
...))
3: ("DEFMETHOD ENSURE-CLASS-USING-CLASS (T NULL)" #<unused-arg>
#<unused-arg>
    OMGENERICFUNCTION #<unavailable-arg> ...)
4: (PCL::REAL-LOAD-DEFCLASS OMGENERICFUNCTION
                            OMCLASS
                            (STANDARD-GENERIC-FUNCTION OMBASICOBJECT)
                            NIL
                            ...)
5: (INTERACTIVE-EVAL
    (DEFCLASS OMGENERICFUNCTION
              (STANDARD-GENERIC-FUNCTION OMBASICOBJECT)
              NIL
              (:METACLASS OMCLASS)))
6: (COMMON-LISP::%TOP-LEVEL)
7: (COMMON-LISP::RESTART-LISP)


Reply via email to