pure
pure copied to clipboard
Improve Box in EnvLang
Currently, EnvLang's Box expression is:
exp = ... | Var vname | Box exp | ...
but it should arguably be:
exp = ... | Var vname | Box vname | ...
because one can always do Let (SOME v) e (Box v) where one would have done Box e before.
This issue is about three changes:
- Making the change above to the expression syntax of EnvLang.
- Allowing
BoxinLetrec, which currently only allowsDelayandLam. - Making sure that #37 replaces
Delay (Var v)withBox valso inLetrec.