Abstract
This paper describes a compiler from the Standard ML core language to a simple intermediate code based on the lambda calculus. It forms an optional part of the SML Kit, an “open” interpreter written in SML which implements the complete SML language faithfully according to the Definition[4], and with an internal modular structure reflecting the structure of the Definition. The interface presented by the compiler to the rest of the Kit is identical to that presented by the Kit’s “pure” interpreter. The lambda compiler is not intended to be an example of how to generate highly efficient code for SML; instead, it serves to illustrate in a clear, modular fashion some of the techniques which are needed to compile core SML into a simple intermediate language. It also shows that a code generating “subsystem” can be added to a pure interpreter so that no details of the compiler or the code generation (or even whether there is a compiler) are visible to the rest of the system.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Bibliography
Andrew W. Appel. Compiling with Continuations. Cambridge University Press, 1992. To appear.
Andrew W. Appel and David B. MacQueen. A Standard ML compiler. In Functional Programming Languages and Computer Architecture, pages 301–324. Springer-Verlag, 1987.
Robin Milner and Mads Tofte. Commentary on Standard ML. MIT Press, 1991.
Robin Milner, Mads Tofte, and Robert Harper. The Definition of Standard ML. MIT Press, 1990.
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 1992 British Computer Society
About this paper
Cite this paper
Rothwell, N. (1992). Functional Compilation from the Standard ML Core Language to Lambda Calculus. In: Heldal, R., Holst, C.K., Wadler, P. (eds) Functional Programming, Glasgow 1991. Workshops in Computing. Springer, London. https://doi.org/10.1007/978-1-4471-3196-0_21
Download citation
DOI: https://doi.org/10.1007/978-1-4471-3196-0_21
Publisher Name: Springer, London
Print ISBN: 978-3-540-19760-7
Online ISBN: 978-1-4471-3196-0
eBook Packages: Springer Book Archive