feat: add trace

This commit is contained in:
rvcas
2022-12-21 14:21:13 -05:00
committed by Lucas
parent 9068c89c00
commit 429126e38f
45 changed files with 315 additions and 23 deletions

View File

@@ -1,14 +1,15 @@
use aiken/builtin
fn is_negative(i : Int) -> Bool {
fn is_negative(i: Int) -> Bool {
if i < 0 {
builtin.trace("is negative", True)
trace("is negative")
True
} else {
builtin.trace("is non-negative", False)
trace("is non-negative")
False
}
}
test trace_1() {
is_negative(-14) && !is_negative(42)
}