diff --git a/src/geometry/scale_construction.rs b/src/geometry/scale_construction.rs index 1f2acf03..cade72c2 100644 --- a/src/geometry/scale_construction.rs +++ b/src/geometry/scale_construction.rs @@ -3,7 +3,7 @@ use crate::base::storage::Owned; #[cfg(feature = "arbitrary")] use quickcheck::{Arbitrary, Gen}; -use num::{One, Zero}; +use num::{One}; #[cfg(feature = "rand-no-std")] use rand::{ distributions::{Distribution, Standard}, @@ -33,9 +33,9 @@ impl Scale { #[inline] pub fn identity() -> Scale where - T: Zero, + T: One, { - todo!(); + Scale::from(SVector::from_element(T::one())) } /// Cast the components of `self` to another type. @@ -55,7 +55,7 @@ impl Scale { } } -impl One for Scale { +impl One for Scale { #[inline] fn one() -> Self { Self::identity()