At 10:24 AM -0700 4/21/04, Jeff Clites wrote:
So are you saying, have separate vtable slots for the hyper operations, but then you only have to fill in the vtable->hyper_add() slot _if_ you want it to do something other than applying vtable->add() in a loop (otherwise, do what your proof-of-concept did)? If so, that makes a lot of sense to me.

Which is what we'd be doing anyway. Splitting the hyper operations out into a secondary vtable is there because generally the entries won't get overridden--sharing the table will cut down on memory usage a bit and hopefully get us a bit more cache coherency.


On the other hand, from what's been said it sounds like Perl6 may not intend to allow you to override a hyper op independently.

Wouldn't be the first bonus thing Larry gets in perl 6, then. One of the Secret Toy Surprises in every box of Perl 6 Flakes. :)


The more I think about it, the more it doesn't make sense to me to allow >>+<< to be overridden independently of +.

The math folks tell me it makes sense. I can come up with a half-dozen non-contrived examples, and will if I have to. :-P


then there wouldn't be any temptation to think of >>+<< as a separate operator.

I think... that'd be bad, generally speaking. (And not just because the math folks have tensors and know what to do with 'em) It's a separate set of operations and, while there are *default* behaviors, there's reason to override those defaults while not touching other things.
--
Dan


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

Reply via email to