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

Function if_without_else_still_compiles

tests/integration/ir_generation.rs:342–351  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

340 while i < 5 {
341 i = i + 1
342 }
343 return i
344}"#;
345 assert!(has_terminator(source, |t| matches!(
346 t,
347 IrTerminator::Jump(..)
348 )));
349}
350
351#[test]
352fn if_without_else_still_compiles() {
353 let source = r#"main: () -> i32 {
354 x: i32 = 1

Callers

nothing calls this directly

Calls 1

compile_okFunction · 0.70

Tested by

no test coverage detected