feat: add map support and tuple deconstruction in let

This commit is contained in:
Kasey White
2022-12-08 05:08:11 -05:00
committed by Lucas
parent 26d2a95618
commit 80a9b7b36a
4 changed files with 699 additions and 172 deletions

View File

@@ -1,7 +1,13 @@
use sample
pub fn spend(datum: sample.Datum, rdmr: sample.Redeemer, _ctx: Nil) -> Bool {
let x = #(datum, rdmr, #[244])
let x = #(datum, #[244])
datum.random == rdmr.signer
let y = [#(#[222], #[222]), #(#[233], #[52])]
let [z, f, ..g] = y
let #(a, b) = x
z == #(#[222], #[222])
}