Compare commits
2 commits
10ef4c6074
...
5c6f538f9e
Author | SHA1 | Date | |
---|---|---|---|
5c6f538f9e | |||
9a1b6fb177 |
3 changed files with 21 additions and 0 deletions
14
README.md
14
README.md
|
@ -2,3 +2,17 @@
|
|||
|
||||
MPRI Functional Programming project, whose subject can be found
|
||||
[here](https://gitlab.inria.fr/fpottier/mpri-2.4-public/blob/master/project/sujet.pdf)
|
||||
|
||||
## Features checklist
|
||||
|
||||
* Performs CPS
|
||||
* Performs defunctionalization
|
||||
* Pretty-prints nicely intermediary languages
|
||||
* Removes var-var bindings
|
||||
|
||||
## Wish list
|
||||
|
||||
* Perform an intelligent CPS transform (many continuations aren't actually even
|
||||
remotely needed at the moment)
|
||||
* Handle correctly functions of arity > 1 (WARNING, cannot partially evaluate a
|
||||
function in C)
|
||||
|
|
2
src/tests/partial_eval.exp
Normal file
2
src/tests/partial_eval.exp
Normal file
|
@ -0,0 +1,2 @@
|
|||
42
|
||||
42
|
5
src/tests/partial_eval.lambda
Normal file
5
src/tests/partial_eval.lambda
Normal file
|
@ -0,0 +1,5 @@
|
|||
let sum = fun x -> fun y -> fun z -> x + y + z in
|
||||
let plus2 = sum 1 1 in
|
||||
|
||||
let _ = print (sum 30 10 2) in
|
||||
print (plus2 40)
|
Loading…
Reference in a new issue