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 issue was labelled with: B-RFC in the Rust repository
Code like this should work, preferably picking the most specialized function (and/or just picking a random one, or the first that matches &c. or just throw a warning)
pub fn abs<T: Signed>(value: T) -> T { value.abs() }
pub fn abs<T: Ord + Zero + Neg<T>>(v: T) -> T { if v < Zero::zero() { v.neg() } else { v } }
The text was updated successfully, but these errors were encountered:
Issue by jensnockert
Tuesday Jun 11, 2013 at 13:58 GMT
For earlier discussion, see rust-lang/rust#7059
This issue was labelled with: B-RFC in the Rust repository
Code like this should work, preferably picking the most specialized function (and/or just picking a random one, or the first that matches &c. or just throw a warning)
The text was updated successfully, but these errors were encountered: