diff --git a/hbbytecode/src/lib.rs b/hbbytecode/src/lib.rs index 488ebe7..80960a0 100644 --- a/hbbytecode/src/lib.rs +++ b/hbbytecode/src/lib.rs @@ -110,7 +110,7 @@ impl TryFrom for RoundingMode { type Error = (); fn try_from(value: u8) -> Result { - (value >= 3) + (value <= 3) .then(|| unsafe { core::mem::transmute(value) }) .ok_or(()) }