Avoid pulling in std for no-std.

This commit is contained in:
Stephen Chung
2020-07-20 20:23:35 +08:00
parent 700060b6e7
commit a5fa8322e9
4 changed files with 8 additions and 0 deletions

View File

@@ -608,6 +608,7 @@ impl Hash for CustomExpr {
#[derive(Debug, PartialEq, PartialOrd, Clone)]
pub struct FloatWrapper(pub FLOAT, pub Position);
#[cfg(not(feature = "no_float"))]
impl Hash for FloatWrapper {
fn hash<H: Hasher>(&self, state: &mut H) {
state.write(&self.0.to_le_bytes());