aurum_numeric/
real.rs

1// Copyright (c) 2016-2017 <daggerbot@gmail.com>
2// This software is available under the terms of the zlib license.
3// See COPYING.md for more information.
4
5/// Get the square root of a number.
6pub trait Sqrt {
7    fn sqrt (self) -> Self;
8}
9
10#[cfg(feature = "std")]
11impl Sqrt for f32 {
12    fn sqrt (self) -> f32 { self.sqrt() }
13}
14
15#[cfg(feature = "std")]
16impl Sqrt for f64 {
17    fn sqrt (self) -> f64 { self.sqrt() }
18}