leo/tests/compiler/statements/ternary_explicit_and_implicit.leo

10 lines
160 B
Plaintext
Raw Normal View History

2021-08-18 11:09:45 +03:00
/*
namespace: Compile
expectation: Pass
input_file: inputs/ternary_explicit_and_implicit.in
*/
function main(x: u8, y: bool) -> u8 {
return y ? x : 2u8;
2021-08-18 11:09:45 +03:00
}