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

Function ir_cmp_signed_negative

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

Source from the content-addressed store, hash-verified

1936 return 1
1937}
1938"#,
1939 );
1940 assert!(
1941 matches!(outcome, RunOutcome::Halted(0)),
1942 "struct fields x=3 y=7 must be readable at correct offsets, got {outcome:?}"
1943 );
1944}
1945
1946/// Struct field arithmetic: compute a value from both fields.
1947#[test]
1948fn struct_field_arithmetic() {
1949 let (_, outcome, _) = run_hll(
1950 r#"
1951divide: (a: i32, b: i32) -> { quotient: i32, remainder: i32 } {
1952 return { .quotient = a / b, .remainder = a % b }
1953}
1954
1955main: () -> i32 {
1956 { quotient: i32, remainder: i32 } = divide(23, 7)
1957 sum: i32 = quotient + remainder
1958 if sum == 5 {

Callers

nothing calls this directly

Calls 1

run_hllFunction · 0.70

Tested by

no test coverage detected