From 35b70661630bbedfc971a883215b9a9b6ba5a4e4 Mon Sep 17 00:00:00 2001 From: KtorZ Date: Sat, 27 Jul 2024 14:12:09 +0200 Subject: [PATCH] Introduce acceptance test 107 illustrating compiler crash ``` crates/aiken-lang/src/gen_uplc.rs:4515:30 internal error: entered unreachable code: Shouldn't call anything other than var or apply Lambda { parameter_name: Name { text: "__no_inline__", unique: Unique( 0, ), }, body: Var( Name { text: "tests_new_list_unbound", unique: Unique( 0, ), }, ), } ``` --- examples/acceptance_tests/107/aiken.lock | 7 +++++++ examples/acceptance_tests/107/aiken.toml | 9 +++++++++ examples/acceptance_tests/107/lib/tests.ak | 7 +++++++ 3 files changed, 23 insertions(+) create mode 100644 examples/acceptance_tests/107/aiken.lock create mode 100644 examples/acceptance_tests/107/aiken.toml create mode 100644 examples/acceptance_tests/107/lib/tests.ak diff --git a/examples/acceptance_tests/107/aiken.lock b/examples/acceptance_tests/107/aiken.lock new file mode 100644 index 00000000..6e350cda --- /dev/null +++ b/examples/acceptance_tests/107/aiken.lock @@ -0,0 +1,7 @@ +# This file was generated by Aiken +# You typically do not need to edit this file + +requirements = [] +packages = [] + +[etags] diff --git a/examples/acceptance_tests/107/aiken.toml b/examples/acceptance_tests/107/aiken.toml new file mode 100644 index 00000000..37a52681 --- /dev/null +++ b/examples/acceptance_tests/107/aiken.toml @@ -0,0 +1,9 @@ +name = "aiken-lang/107" +version = "0.0.0" +license = "Apache-2.0" +description = "Aiken contracts for project 'aiken-lang/107'" + +[repository] +user = "aiken-lang" +project = "107" +platform = "github" diff --git a/examples/acceptance_tests/107/lib/tests.ak b/examples/acceptance_tests/107/lib/tests.ak new file mode 100644 index 00000000..431a5c2b --- /dev/null +++ b/examples/acceptance_tests/107/lib/tests.ak @@ -0,0 +1,7 @@ +fn new_list() { + [] +} + +test foo() { + fn() { new_list }()() == [] +}