Add the tiger source code bundle from the book site

Signed-off-by: jmug <u.g.a.mariano@gmail.com>
This commit is contained in:
Mariano Uvalle 2024-12-18 15:18:45 -08:00
parent 915660c8a7
commit 33d8bac511
87 changed files with 3252 additions and 0 deletions

14
tiger/testcases/test5.tig Normal file
View file

@ -0,0 +1,14 @@
/* define valid recursive types */
let
/* define a list */
type intlist = {hd: int, tl: intlist}
/* define a tree */
type tree ={key: int, children: treelist}
type treelist = {hd: tree, tl: treelist}
var lis:intlist := intlist { hd=0, tl= nil }
in
lis
end