anoma / geb

A Categorical View of Computation
https://anoma.github.io/geb/
GNU General Public License v3.0
28 stars 10 forks source link

STLC to Geb Compilation Fix #127

Closed agureev closed 1 year ago

agureev commented 1 year ago

Fixes the compilation of STLC to Geb discarding previous uncurrying changes in favour of uncurrying only the final result. Add tests for identity and not functions compiled from STLC code, as well as compilation test for higher-order functions.

Change case-on case for compilation to get rid of pattern-matching.

Note that not all tests are passed. Those that are not, involve using gapply on the morphisms compiled from Geb code involving distributivity and hence swap evaluation in BITC. Adding fixes from #124 makes all tests pass.