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

Re: Continuing comments on Draft 11

    Date: Fri, 2 Nov 1990 16:11 EST
    From:	Gregor Kiczales <Gregor@parc.xerox.COM>

    If the user wanted to define a new class of method that added a lexical
    function binding FOO around the body they would define a method like:

    (defmethod make-method-lambda ((gf standard-generic-function)
				   (method my-method-1)
      (call-next-method gf
			`(,(car lambda) ,(cadr lambda)
			   `(flet ((foo ..)) ,(cddr lambda)))

This would work (if you fixed the bug) just as well if you didn't say
that make-method-lambda returned a function which took two arguments, so
I don't see why you should be saying it.

    METHOD-FUNCTION, on a method, would return a function of two arguments
    (a list of args and a list of next methods).  This is important to have
    for things like user-built steppers.  The implementation-model would be
    that impls would call METHOD-FUNCTION, but, as usual, they don't have to
    call it if they know what they are going to get.  That is, there are no
    relevant meta-level incursions.

If a function FUNCALL-METHOD-LAMBDA took arguments of a
MAKE-METHOD-LAMBDA's first and second values, a list of next methods, a
boolean of whether or not next methods were allowed, and the arguments
to the function, I could write such a FUNCALL-METHOD-LAMBDA function.
Is that good enough for a stepper?