leo/tests/compiler/integers/i16/ternary.leo
2022-08-04 20:00:40 -07:00

15 lines
212 B
Plaintext

/*
namespace: Compile
expectation: Pass
input_file:
- inputs/tern.in
- inputs/tern_rev.in
*/
@program
function main(s: bool, a: i16, b: i16, c: i16) -> bool {
let r: i16 = s ? a : b;
return r == c;
}