Add writeBits back in and use the optimizer to utilize the list conversion
This commit is contained in:
2
examples/acceptance_tests/117/aiken.toml
Normal file
2
examples/acceptance_tests/117/aiken.toml
Normal file
@@ -0,0 +1,2 @@
|
||||
name = "aiken-lang/acceptance_test_117"
|
||||
version = "0.0.0"
|
||||
17
examples/acceptance_tests/117/lib/tests.ak
Normal file
17
examples/acceptance_tests/117/lib/tests.ak
Normal file
@@ -0,0 +1,17 @@
|
||||
use aiken/builtin.{write_bits}
|
||||
|
||||
test bar() {
|
||||
let x =
|
||||
if True {
|
||||
[0, 1, 2, 3]
|
||||
} else {
|
||||
[0, 1]
|
||||
}
|
||||
|
||||
write_bits(#"f0", x, True) == #"ff"
|
||||
}
|
||||
|
||||
test baz() {
|
||||
let x = [0, 1, 2, 3]
|
||||
write_bits(#"f0", x, True) == #"ff"
|
||||
}
|
||||
Reference in New Issue
Block a user