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

Re: macros vs. blocks



Avi Bryant <avi@beta4.com> writes:

> Note that you couldn't easily do this in Scheme (because you can't
> add methods to arithmetic functions, for example) or even in CLOS
> (because there's no equivalent of Smalltalk's #doesNotUnderstand:).

I've never seen this style used in CLOS but you could add methods to
the NO-APPLICABLE-METHOD generic function. A bigger problem for this
specific example is that the arithmetic functions aren't (guaranteed
to be) generic functions in CL.

-- 
When they ran out of ships, they used guns. When they ran out of guns,
they used knives and sticks and bare hands. They did this for two
years. They never ran out of courage. But in the end, they ran out of
time.                                          B5 --- In the Beginning