1
1
mirror of https://github.com/anoma/juvix.git synced 2024-12-18 20:31:51 +03:00
juvix/test/Nockma/Compile
Paul Cadman 06d459695d
Use Anoma compatible Nockma serialization of Bools and List-like data structures (#2591)
This PR changes the Nockma representation of builtin Bool and list-like
types to make them compatible with Anoma.

True and False are now compiled to the Nockma atoms 0 and 1
respectively.

For inductive types that have exactly two constructors, one of arity
zero and one of arity two, we compile the arity zero constructor to
Nockma zero, and the arity two constructor to a Nockma cell. In
particular a Juvix stdlib List will be compiled to an Anoma/Nockma list.
This is necessary for compatibility with the layout of resource and
resource logic types in Anoma.

In tests we avoid using the StackRef memory reference because it will be
removed as part of the JuvixTree work.

---------

Co-authored-by: Łukasz Czajka <62751+lukaszcz@users.noreply.github.com>
2024-01-24 15:16:04 +00:00
..
Asm Fast nockma eval (#2580) 2024-01-19 12:01:58 +01:00
Positive.hs Use Anoma compatible Nockma serialization of Bools and List-like data structures (#2591) 2024-01-24 15:16:04 +00:00