guile-user
[Top][All Lists]
Advanced

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

Re: GOOPS: define-method* with extended lambda-list-syntax?


From: Mikael Djurfeldt
Subject: Re: GOOPS: define-method* with extended lambda-list-syntax?
Date: Thu, 10 Apr 2003 20:00:08 +0200
User-agent: Gnus/5.090017 (Oort Gnus v0.17) Emacs/21.2 (gnu/linux)

Anders Vinjar <address@hidden> writes:

>>>>>> "MD" == Mikael Djurfeldt <address@hidden> writes:
>
>     >> (define-method* (f (x <real>) (y <top>) #:optional z)
>     >> 'real-top)
>
>     MD> It might be good to "fold in" the functionality of
>     MD> lambda* so that you can have some decisions already made
>     MD> by method dispatch.
>
> Id be very happy if you could explain what you're thinking of
> here.  lambda* is put to use in the procedure definitions left
> with the specialised methods.
>
> You're maybe suggesting that taking a look at how lambda* builds
> its code based on walking its arguments would be helpful in this
> issue?

Yes.

The method with specializers (<real> <top> <top>) can assume that the
optional argument is present, while the method with specializers
(<real> <top>) can assume that it is not present.

This means that the work normally done by the generic lambda* (which
makes no such assumptions) can be simplified for each of the two
methods.

Best regards,
Mikael D.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]