diff options
author | Alon Zakai <alonzakai@gmail.com> | 2016-02-02 19:11:52 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2016-02-02 19:20:44 -0800 |
commit | bdcc9c30e68e63ac2b17a415d9aceff3e62bbd07 (patch) | |
tree | 84c65acfd776f8869a074f9c391ecc1e1e329987 | |
parent | d467c8f522d7ed8e495b548a753b5f599f7778fa (diff) | |
download | binaryen-bdcc9c30e68e63ac2b17a415d9aceff3e62bbd07.tar.gz binaryen-bdcc9c30e68e63ac2b17a415d9aceff3e62bbd07.tar.bz2 binaryen-bdcc9c30e68e63ac2b17a415d9aceff3e62bbd07.zip |
fix nan comparisons
-rw-r--r-- | src/wasm.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/wasm.h b/src/wasm.h index 51b54846a..7a792fda4 100644 --- a/src/wasm.h +++ b/src/wasm.h @@ -207,10 +207,10 @@ public: if (type != other.type) return false; switch (type) { case WasmType::none: return true; - case WasmType::i32: - case WasmType::f32: return i32 == other.i32; - case WasmType::i64: - case WasmType::f64: return i64 == other.i64; + case WasmType::i32: return i32 == other.i32; + case WasmType::f32: return getf32() == other.getf32(); + case WasmType::i64: return i64 == other.i64; + case WasmType::f64: return getf64() == other.getf64(); default: abort(); } } |