Fix errors on aiken build

- Update generics syntax
- Add required args to default validator function

This allows running a successful aiken build from
files generated by aiken new.
This commit is contained in:
Carlos Souza
2022-12-14 11:19:39 -05:00
committed by Lucas
parent 95986fed83
commit c77b7c293b

View File

@@ -54,7 +54,7 @@ impl Creator {
write(
self.validators.join("always_true.ak"),
indoc! {"
pub fn spend() -> Bool {
pub fn spend(_datum, _redeemer, _context) -> Bool {
True
}
"},
@@ -76,7 +76,7 @@ impl Creator {
write(
self.project_lib.join("context.ak"),
indoc! {"
pub type ScriptContext(purpose) {
pub type ScriptContext<purpose> {
tx_info: TxInfo,
script_purpose: purpose,
}