Fix UnitComplex cast doctest failure on macOS

This commit is contained in:
Jacob Trueb 2022-05-25 17:51:19 -05:00
parent b656faa233
commit 0cdf3ce452
1 changed files with 2 additions and 1 deletions

View File

@ -131,10 +131,11 @@ where
///
/// # Example
/// ```
/// #[macro_use] extern crate approx;
/// # use nalgebra::UnitComplex;
/// let c = UnitComplex::new(1.0f64);
/// let c2 = c.cast::<f32>();
/// assert_eq!(c2, UnitComplex::new(1.0f32));
/// assert_relative_eq!(c2, UnitComplex::new(1.0f32));
/// ```
pub fn cast<To: Scalar>(self) -> UnitComplex<To>
where