feat: some new features

- tuples `#(Int, Int)`
- `trace` and `trace("text")`
This commit is contained in:
rvcas
2022-11-28 22:24:15 -05:00
committed by Lucas
parent 6066e3176c
commit 0823b78bf8
17 changed files with 335 additions and 223 deletions

View File

@@ -36,12 +36,17 @@ pub fn incrementor(counter: Int, target: Int) -> Int {
}
}
pub fn who(a: #(Int, Int)) -> #(Int, Int) {
#(1, 2)
}
pub fn spend(
datum: sample.Datum,
rdmr: Redeemer,
ctx: spend.ScriptContext,
) -> Bool {
let x = Sell
let z = incrementor(0, 4) == 4
z
when [1, 2, 3] is {
[a, b, ..] -> True
[] -> False
}
}