| Directory | File | Contents | Lecture | Zip-file |
|---|---|---|---|---|
| . | General tools | |||
| Env.sig, Env.sml | Environment implementation | top.zip | ||
| Naivestore.sig, Naivestore.sml | Naive store implementation | |||
| Sto.sig, Sto.sml | Store implementation | |||
| cont/ | Continuation-passing style | |||
| fun.sml | Continuation-passing interpreter for a functional language | 8 | cont.zip | |
| imp.sml | Continuation-passing interpreter for an imperative language | |||
| Factorial.java | Continuation-passing style factorial function in Java | |||
| expr/ | A simple expression language | |||
| grammar.txt | Informal grammar description | 2, 3 | expr.zip | |
| Absyn.sml | Abstract syntax | |||
| Exprlex.lex | Lexer specification | |||
| Exprpar.grm | Parser specification | |||
| parse.sml | Definition of parse functions | |||
| expr.sml | Expression interpreter (eval) and compilers | |||
| Stack.java | Abstract stack machine for expression evaluation | |||
| ex1.ex | Well-formed expression for parser testing | |||
| bad1.ex-bad8.ex | Ill-formed expressions for parser testing | |||
| fun/ | A first-order and a higher-order functional language | |||
| grammar.txt | Informal grammar description | 4, 5 | fun.zip | |
| Absyn.sml | Abstract syntax | |||
| Funlex.lex | Lexer specification | |||
| Funpar.grm | Parser specification | |||
| parse.sml | Definition of parse functions | |||
| fun.sml | First-order functional language interpreter | |||
| tychk.sml | Definition of an explicitly typed functional language, and its type checker | |||
| hofun.sml | Higher-order functional language interpreter | |||
| tyinf.sml | Type inference for the hofun language | |||
| imp/ | Micro-C, an imperative language | |||
| grammar.txt | Informal grammar description | 6, 7, 9, 10 | imp.zip | |
| Absyn.sml | Abstract syntax | |||
| Clex.lex | Lexer specification | |||
| Cpar.grm | Parser specification | |||
| parse.sml | Definition of parse functions | |||
| c.sml | Micro-C interpreter | |||
| Machine.sml | Definition of abstract machine code, used by comp.sml and contcomp.sml | |||
| comp.sml | Compiler from micro-C to stack machine | |||
| Machine.java | Abstract stack machine for micro-C code execution | |||
| contcomp.sml | Continuation-based compiler from micro-C to stack machine | |||
| jvmcomp.sml | Continuation-based compiler from micro-C to Java bytecode | |||
| ex1.c-ex20.c | Example programs in micro-C | |||
| ex13.java | Example program in Java | |||
| InOut.java | Library for running micro-C programs as Java programs | |||
| ex13.cs | Example program in C# | |||
| oo/ | Micro-Java, a small subset of Java | |||
| grammar.txt | Informal grammar description | 11 | oo.zip | |
| Absyn.sml | Abstract syntax | |||
| Oolex.lex | Lexer specification | |||
| Oopar.grm | Parser specification | |||
| parse.sml | Definition of parse functions | |||
| oo.sml | Interpreter for micro-Java | |||
| Util.java | Used for running micro-Java programs as Java programs | |||
| ex1.java-ex4.java | Example programs in micro-Java | |||
| rtcg/ | Reflection and runtime code generation | |||
| Reflect0.cs-Reflect2.cs | Reflection in C# | 12 | rtcg.zip | |
| Reflect0.java-Reflect4.java | Reflection in Java | |||
| RTCG1.cs-RTCG6.cs | Runtime code generation in C# | |||
| RTCG2.java-RTCG4.java | Runtime code generation in Java | |||
| usql/ | Micro-SQL, a small subset of SQL | |||
| grammar.txt | Informal grammar description | 3 | usql.zip | |
| Absyn.sml | Abstract syntax | |||
| Sqllex.lex | Lexer specification | |||
| Sqlpar.grm | Parser specification | |||
| parse.sml | Definition of parse functions | |||