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

SYS:PRINT-SELF for CLOS.



    Date: Fri, 16 Mar 90 09:43 PST
    From: RDP@ALAN.kahuna.decnet.lasc-research.lockheed.com (Robert D.
	  Pfeiffer)

    I have just performed a reasonably major Flavors to CLOS conversion
    under Genera 8.0 Beta using the Conversion Tools.  I was very pleased
    with how well it went (took about two days) and the Conversion Tools
    worked like a charm.

    The application is almost running again but I have one problem to deal
    with.  Under Flavors I have defined many methods for SYS:PRINT-SELF.  If
    I try to simply convert them to CLOS methods, I get the following
    compile-time error: 

1    Error: SYS:PRINT-SELF was previously defined as a function, but is now being used as a generic function.

    CLOS-INTERNALS::REDEFINING-FUNCTION-AS-GENERIC-ERROR
0       Arg 0 (CLOS-INTERNALS::FUNCTION-NAME): SYS:PRINT-SELF
       Arg 1: NIL
    s-A, :    Remove the previous definition.
    s-B:           Skip compiling form (CLOS-INTERNALS::DEFMETHOD-INTERNAL 'SYS:PRINT-SELF ...)
    s-C:           Skip compiling form (CLOS:DEFMETHOD SYS:PRINT-SELF ...)
    s-D, :    Editor Top Level
    s-E:           Restart process Zmacs Windows

    I think what the error actually means is that SYS:PRINT-SELF was
    previously defined as a Flavor generic function and now I'm trying to
    redefine it as a CLOS generic function.  Naturally, I don't want to
    "Remove the previous definition."  But it's not particularly clear to me
    what I really should do.

    Surely there must be an straightforward way to deal with this?

I think the corresponding CLOS generic function is really CLOS:PRINT-OBJECT.
Try using that name instead of SYS:PRINT-SELF.

 -- Chuck Fry
    Symbolics Software Support