diff --git a/src/structs/dmat.rs b/src/structs/dmat.rs index 6046bb79..de452f6e 100644 --- a/src/structs/dmat.rs +++ b/src/structs/dmat.rs @@ -12,7 +12,7 @@ use std::mem; use structs::dvec::DVec; use traits::operations::{Inv, Transpose, Mean, Cov}; use traits::structure::{Cast, ColSlice, RowSlice, Diag, Eye, Indexable, Shape, Zero, One, BaseNum}; -use std::fmt::{Show, Debug, Formatter, Result, String}; +use std::fmt::{Debug, Display, Formatter, Result}; #[cfg(feature="arbitrary")] use quickcheck::{Arbitrary, Gen}; @@ -634,7 +634,7 @@ impl> ApproxEq for DMat { } } -impl Debug for DMat { +impl Debug for DMat { fn fmt(&self, form:&mut Formatter) -> Result { for i in (0us .. self.nrows()) { for j in (0us .. self.ncols()) { diff --git a/tests/mat.rs b/tests/mat.rs index a38adf7c..07dcddf1 100644 --- a/tests/mat.rs +++ b/tests/mat.rs @@ -127,7 +127,7 @@ fn test_inv_mat6() { fn test_rotation2() { for _ in (0us .. 10000) { let randmat: na::Rot2 = na::one(); - let ang = Vec1::new(na::abs(&random::()) % BaseFloat::pi()); + let ang = Vec1::new(na::abs(&random::()) % ::pi()); assert!(na::approx_eq(&na::rotation(&na::append_rotation(&randmat, &ang)), &ang)); } @@ -145,7 +145,7 @@ fn test_inv_rotation3() { for _ in (0us .. 10000) { let randmat: Rot3 = na::one(); let dir: Vec3 = random(); - let ang = na::normalize(&dir) * (na::abs(&random::()) % BaseFloat::pi()); + let ang = na::normalize(&dir) * (na::abs(&random::()) % ::pi()); let rot = na::append_rotation(&randmat, &ang); assert!(na::approx_eq(&(na::transpose(&rot) * rot), &na::one()));