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
The corresponding std::ops traits have both the type of right hand side operand and the type of result, while Checked* traits do not (and always assume that both operands and result have the same type). There is no real reason to make Checked* traits behave differently from std::ops traits, and having them as is hampers advanced uses of operator overloading: for example, if the scalar type (e.g. DateTime) and difference type (e.g. Duration) are distinct from each other then the current scheme wouldn't work at all.
The text was updated successfully, but these errors were encountered:
…ssify, r=llogiq
Cleanup `const_float_classify`
As mentioned at rust-lang#13508 `const_float_classify` has been stabilized recently in rust-lang#130157 and can be cleanup
Closerust-lang#13508
changelog: [none]
The corresponding
std::ops
traits have both the type of right hand side operand and the type of result, whileChecked*
traits do not (and always assume that both operands and result have the same type). There is no real reason to makeChecked*
traits behave differently fromstd::ops
traits, and having them as is hampers advanced uses of operator overloading: for example, if the scalar type (e.g.DateTime
) and difference type (e.g.Duration
) are distinct from each other then the current scheme wouldn't work at all.The text was updated successfully, but these errors were encountered: