mirror of
https://github.com/ProvableHQ/leo.git
synced 2024-11-23 15:15:47 +03:00
23 lines
416 B
Plaintext
23 lines
416 B
Plaintext
/*
|
|
namespace: Compile
|
|
expectation: Fail
|
|
input_file: inputs/dummy.in
|
|
*/
|
|
|
|
program test.aleo {
|
|
function main(a: u32, b: u32, y: bool) -> u32 {
|
|
if y {
|
|
return adder(a, b);
|
|
} else {
|
|
return subber(a, b);
|
|
}
|
|
}
|
|
|
|
function adder(a: u32, b: u32) -> u32 {
|
|
return a + b;
|
|
}
|
|
|
|
function subber(a: u32, b: u32) -> u32 {
|
|
return a - b;
|
|
}}
|