-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathREADME
28 lines (20 loc) · 863 Bytes
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
Lambda - A small lambda calculus interpreter in C
License: MIT/X
Interpret lambda terms using two reduction strategies, call-by-name or
call-by-value. Default is call-by-name and you can use call-by-value
by using the -v option.
Use lambda by launching it and typing lambda terms. They will be
evaluated and the result will be printed. To end an input session use
^C or ^D or, type '.'.
The syntax of lambda terms is as follows. Variables are one char long.
Applications is coded by juxtaposing two terms. Abstractions are
encoded by prefixing '\v' to a term were 'v' is the variable
abstracted. Blanks are non-significative. Parenthesis are allowed to
delimit terms.
Here is a list of sample terms:
\x x
(\x x) 3
(\x xx)(\x xx)
Note that application is left associative, as usual in lambda
calculus, thus 'abc' stands for '(ab)c'.
vim: set tw=70: