Files
Abstract
In a 1972 paper, John C. Reynolds outlined a method for removing higher order functions from a functional language program by representing functional values as data and interpreting the representations as needed. This transformation is known as defunctionalization. This thesis describes an automated defunctionalization system that transforms a significant portion of core Standard ML syntax. Modern functional language features
addressed by this research include pattern matching, parametric polymorphism, "mul
tiple alternate" expressions, local declarations, and function values contained in data
structures. This research elaborates on details not explained in earlier presentations of
the defunctionalization method, including detection of higher order functions, function
values that are "shared" by several higher order functions, and higher order functions
with higher order parameters.