At 9:27 PM -0400 9/4/02, Ken Fox wrote: >Dan Sugalski wrote: >>At 9:10 AM -0400 9/4/02, [EMAIL PROTECTED] wrote: >>>So, just to clarify, does that mean that multi-dispatch is (by definition) >>>a run-time thing, and overloading is (by def) a compile time thing? >> >>No. They can be both compile time things or runtime things, >>depending on the characteristics of the language. > >I don't think so. Those terms are well understood by the OO community. >Bertrand Meyer wrote on the subject: >http://www.inf.ethz.ch/personal/meyer/publications/joop/overloading.pdf
Yeah, but what he wrote was "don't do that, in any of its forms." While an interesting argument, it's a touch late for perl. >Prior to C++ there might have been some ambiguity (for example, some >people have talked about run-time vs compile-time overloading), but >C++ has completely stolen the term. Here's a slide from one of Damian's >presentations that states multi-methods are "Like C++ overloading, >but polymorphic." >http://www.csse.monash.edu.au/~damian/TPC/1999/MultipleDispatch/Presentation/sld010.htm Hrm. I generally use "overloading" in the "operator overloading" sense, which is where the confusion comes in, I expect. Operator overloading can be a compile or runtime thing, depending on your preferences. Figuring out what function/method to call based on parameters and return types can also be a runtime or compile time thing, once again depending on preferences. -- Dan --------------------------------------"it's like this"------------------- Dan Sugalski even samurai [EMAIL PROTECTED] have teddy bears and even teddy bears get drunk