You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This turns out to be much harder than I thought. In fact, Martin Odersky is proposing such a thing for Dotty. I'll just have to leave this open and see what happens. I'm concerned with moving to Dotty as most people aren't using it (I think).
Due to the JVM's insistence that everything has an
equals
method thatAny
we have ugly code. Take for example this snippet from
Polynomial
:The
asInstanceOf
guard is ugly and gets repeated anywhere I want to have a specific notion of equality. As of the writing of this issue, it appears inPolynomial
ResidueClass
RationalExpression
Create a trait that handles the type guard and allows the user to simply write the actual equality logic on the appropriate type.
The text was updated successfully, but these errors were encountered: