From a99175669fba6970df107cda657567a6267a4e0c Mon Sep 17 00:00:00 2001 From: Kolby Heacock Date: Thu, 4 Dec 2025 12:40:27 -0700 Subject: [PATCH] updated BVTON --- hyphae/src/vm.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/hyphae/src/vm.rs b/hyphae/src/vm.rs index 2b807b5..dd77225 100644 --- a/hyphae/src/vm.rs +++ b/hyphae/src/vm.rs @@ -413,10 +413,9 @@ impl VM { }), i::BVTON => access!(&instr.1[0], { - if let Datum::ByteVector(sbv) = **access!(&instr.1[0]) { - let sf64 = f64::from_ne_bytes(sbv.try_into().unwrap()); - Ok::(Datum::Number(Number::Flt(Float(sf64)))); - //Datum::Number(Number::Fra(Fraction(sf64 as isize, 1))).into() + if let Datum::ByteVector(sbv) = &**access!(&instr.1[0]) { + let sf64 = f64::from_ne_bytes(sbv.clone().try_into().unwrap()); + Datum::Number(Number::Flt(Float(sf64))).into() } else { e!("illegal argument to BVTON instruction"); }