You may get more mileage by having a matrix operation interface that has is parameterised over the two matrix types. It would have things like multiply once and you would have different concrete implementations for different pairs of matrix types. The implementations can even be provided via one of the matrix classes to allow it to take advantage of the matrix internal structure without exposing it.
On 1 Jul 2011 22:49, "Ted Dunning" <ted.dunn...@gmail.com> wrote: Double dispatch was the wrong term. I should have said double argument polymorphism. Double dispatch is a sub-optimal answer to the problem of double polymorphism. Apologies for polluting the discussion with a silly error. On Fri, Jul 1, 2011 at 2:35 PM, Greg Sterijevski <gsterijev...@gmail.com >wrote: > Ted, > > I am not sure why you think there will be double dispatch. If we remove the > multiplica...