Multiple Dispatch

Stephane Ducasse ducasse at iam.unibe.ch
Mon Jun 16 06:35:23 UTC 2003


Hi lex

I worked with CLOS during 4 years and I did not find the advantage of 
multi dispatch.
You know this is like multiple inheritance you need that in 5% of the 
case and it
makes the language much more complex for the rest 95%

Stef

On Sunday, June 15, 2003, at 01:10 PM, Lex Spoon wrote:

> Joel Shellman <joel at ikestrel.com> wrote:
>> I'm familiar with double dispatch, I was asking about multiple 
>> dispatch (of
>> which double dispatch is a subset), so I'll take that as a no.
>
> Incidentally, guys, hand-coded double-dispatch is nothing like
> multi-dispatch supported in the language, where you can say things 
> like:
>
> 	<Integer> + aNumber <Integer>
> 		"code for adding an integer"
>
>
> 	<Integer> + aNumber <Number>
> 		"default code for adding any number"
>
>
>
> I'm surprised if no one has hacked something together to do this....
>
> Incidentally, it would be really nice if the things in <> didn't have 
> to
> be classes, but could be some sort of interface, e.g. if it could be a
> trait from Nathanael Schaerli's work.
>
>
>
> Lex
>



More information about the Squeak-dev mailing list