This commit is contained in:
microproofs 2024-05-06 11:35:05 -04:00
parent 14903f7352
commit 2f61f59b60
4 changed files with 47 additions and 0 deletions

View File

@ -1128,10 +1128,16 @@ impl Assertion<UntypedExpr> {
.to_string()
};
// head did not map to a constant
if self.head.is_err() {
return red("program failed");
}
// any value in tail did not map to a constant
if self.tail.is_err() {
return red("program failed");
}
fn fmt_side(side: &UntypedExpr, stream: Stream) -> String {
let __ = "".if_supports_color(stream, |s| s.red());

View File

@ -0,0 +1,16 @@
# This file was generated by Aiken
# You typically do not need to edit this file
[[requirements]]
name = "aiken-lang/stdlib"
version = "main"
source = "github"
[[packages]]
name = "aiken-lang/stdlib"
version = "main"
requirements = []
source = "github"
[etags]
"aiken-lang/stdlib@main" = [{ secs_since_epoch = 1715006768, nanos_since_epoch = 293270000 }, "5ee55dc5ccf269bb493f4cacb32096f0191a6adb2ef39d62a1f79b8c5a8fcc7f"]

View File

@ -0,0 +1,14 @@
name = "aiken-lang/102"
version = "0.0.0"
license = "Apache-2.0"
description = "Aiken contracts for project 'aiken-lang/102'"
[repository]
user = "aiken-lang"
project = "102"
platform = "github"
[[dependencies]]
name = "aiken-lang/stdlib"
version = "main"
source = "github"

View File

@ -0,0 +1,11 @@
test panic_aiken() {
and {
True,
should_fail(1),
}
}
fn should_fail(num) {
expect num == 0
True
}