1
1
mirror of https://github.com/anoma/juvix.git synced 2024-11-30 14:13:27 +03:00
juvix/tests/Core
Paul Cadman 49c14be71e
Fix nock compilation and builtin evaluation of sha256 stdilb (#3175)
This PR:

1. Fixes the compilation of the sha256 builtin anoma lib call

A sha256 hash is 32 bytes long, not 64 bytes. This number is used when
constructing the ByteArray representation (i.e `[length payload]` cell)
of the output of Anoma stdlib sha256 call. The Anoma stdlib sha256 call
just returns the atom payload.

2. Fixes the evaluation of the sha256 stdlib call

Previously we were converting the sha256 hash bytestring to Base16
format. This is convenient when displaying the ByteString hash. However
the Anoma nock interpreter outputs the raw bytes so we must change the
builtin evaluator to match this behaviour.

After these fixes we can re-enable the test084 anoma compilation test.
2024-11-14 18:54:39 +01:00
..
benchmark Add debugging builtin functions trace and fail (#1771) 2023-01-27 12:45:38 +01:00
negative Add debugging builtin functions trace and fail (#1771) 2023-01-27 12:45:38 +01:00
positive Fix nock compilation and builtin evaluation of sha256 stdilb (#3175) 2024-11-14 18:54:39 +01:00