[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: email@example.com
- Subject: define-condition, defclass
- From: donc@ISI.EDU (Don Cohen)
- Date: Fri, 7 Oct 94 10:26:24 -0700
- Posted-date: Fri, 7 Oct 94 10:26:24 -0700
I've noticed that clisp differs from some other lisps in how it
translates define-condition. Suppose you just want to define a
subclass of CONDITION. CLtL2 doesn't seem to say whether you need
(define-condition foo (CONDITION) nil) or whether
(define-condition foo () nil) is enough.
First question - does anyone know whether the ANSI standard says any
more about this?
In clisp the second works but the first does not! Part of the reason
is that in clisp, define-condition ALWAYS adds CONDITION at the end:
> (macroexpand-1 '(define-condition foo (bar baz) nil))
(CLOS:DEFCLASS FOO (BAR BAZ CONDITION) NIL) ;
The rest of the problem is that defclass doesn't like the resulting
two occurrences of CONDITION. I don't see why that's a problem. It
seems to work in other lisps.
Second question - is this a bug in clisp, or am I missing something?