At 11:24 AM +0100 3/14/04, Leopold Toetsch wrote:
Dan Sugalski <[EMAIL PROTECTED]> wrote:
 ... --should we have the
 base object system participate in multimethod dispatch? That is, if
 someone does an:

add P1, P2, P3

 and P2 is a parrot object, should that add vtable method
 automatically redispatch to MMD if the vtable method can't be found
 in P2's class hierarchy?

Could be useful, sometimes. But why would one write a mathematical class that then uses default addtion?

One wouldn't. One *might* write a class that makes assumption about the RHS (like, for example, that you can just yank out the integer value) but that'd be sub-optimal.


I think MMD is the way to go, so I'm working on the scheme to install MMD methods for vtable functions. And yeah, I'm re-evaluating dispatch to these things too. I'd like to avoid the round-trip through C if we can, since bytecode vtable functions may end up being popular. (And there's that whole dispatch-messes-up-DOD thing...)
--
Dan


--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to