Skip to content

Commit c46d7a5

Browse files
authored
fix: add mantissa variable (fixes #37)
1 parent b5bb2d1 commit c46d7a5

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

ch5/ch5-visualizing-f32.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ fn decode(
3434

3535
let exponent = (exponent as i32) - BIAS; // <8>
3636
let exponent = RADIX.powf(exponent as f32); // <8>
37+
38+
let mut mantissa: f32 = 1.0;
3739

3840
for i in 0..23 { // <9>
3941
let mask = 1 << i; // <9>

0 commit comments

Comments
 (0)