Add no_std and forbid(unsafe) in utils
This commit is contained in:
1 parent
00fcdf1031
commit
df05c06270
3 files changed
+34
-9
No files matched your search
@@ -1,5 +1,5 @@
|
||||
//! The Float type used throughout the ecosystem
|
||||
|
||||
#![no_std]
|
||||
#![cfg_attr(feature = "fast-float", feature(core_intrinsics))]
|
||||
|
||||
/// Type used for floats, configure with the `f32` feature
|
||||
@@ -12,9 +12,9 @@ pub type Float = f64;
|
||||
/// Associated constants for [`Float`]
|
||||
pub mod consts {
|
||||
#[cfg(feature = "f32")]
|
||||
pub use std::f32::consts::*;
|
||||
pub use core::f32::consts::*;
|
||||
#[cfg(not(feature = "f32"))]
|
||||
pub use std::f64::consts::*;
|
||||
pub use core::f64::consts::*;
|
||||
}
|
||||
|
||||
#[cfg(feature = "fast-float")]
|
||||
|
||||
Reference in new issue
Block a user