MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / cast_u8_high_bit_zero_extends

Function cast_u8_high_bit_zero_extends

tests/integration/vm_execution.rs:2486–2507  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2484 return h as i32
2485}
2486"#,
2487 );
2488 // 9.0 + 0.5 = 9.5, * 2.0 = 19.0 -> 19.
2489 assert!(
2490 matches!(outcome, RunOutcome::Halted(19)),
2491 "expected Halted(19), got {outcome:?}"
2492 );
2493}
2494
2495#[test]
2496fn float_f32_to_f64_widen() {
2497 // f32 -> f64 conversion (fcvt.d.s). 3.5 widened, + 1.5 = 5.0 -> 5.
2498 let (_, outcome, _) = run_hll(
2499 r#"
2500main: () -> i32 {
2501 a: f32 = 3.5
2502 onefive: f64 = 1.5
2503 b: f64 = a as f64
2504 c: f64 = b + onefive
2505 return c as i32
2506}
2507"#,
2508 );
2509 assert!(
2510 matches!(outcome, RunOutcome::Halted(5)),

Callers

nothing calls this directly

Calls 1

run_hllFunction · 0.70

Tested by

no test coverage detected