Posts

Showing posts from April, 2019

The implementation of functional programming languages

So I've started  SLPJ's "The implementation of functional programming languages"  and these and my reading notes, on-going questions and summary. Summary Overall outline. Part I: translate a non-strict FPL (Miranda taken as an example) to a first intermediate representation (enriched lambda calculus), then to lambda calculus. Part II: an implementation of lambda calculus is given. Part III: an efficient implementation is proposed. Questions Can we skip part II? "It seems than graph reduction is probably less attractive than environment-based approach for language with strict semantic". Why is that? (TODO: check after chapter 11 if we are able to answer this question). "A functional language has a natural representation as a tree". But... "graph reduction". Are we talking about the same thing? An IR with recursion might not be a tree anymore. Or, should we talk about tree reduction? Built-in functions are introduced for