Unlambda interpreter
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
test
LICENSE
Makefile
README.md
run_tests
unlambda.c

README.md

Unlambda interpreter

This is a fast and memory-efficient interpreter of the Unlambda programming language.

Features

  • Generational garbage collection
  • Internally substitutes terms of some patterns, so that they evaluate faster and use less memory. The following substitution rules are implemented:
     `S`Kf -> `Bf    where ```Bfgx = `f`gx
   ``Sf`Kg -> ``Cfg  where ```Cfgx = ``fxg
   ``SI`Kx -> `Tx    where   ``Txy = `yx
 ``S`Tx`Ky -> ``Vxy  where ```Vxyz = ``zxy

Usage

$ unlambda [-v[0-3]] [program-file]

If program-file is not specified, Unlambda program is read from the standard input.

The -v[0-3] option sets the verbosity level.

  • -v0 (default): Do not print any debug information.
  • -v1: Print some statistics after execution.
  • -v2: Print logs for major GCs.
  • -v3: Print logs for minor GCs.

License

MIT