State in Haskell

Some algorithms make critical internal use of updatable state, even though their external specification is purely functional. Based on earlier work on monads, we present a way of securely encapsulating stateful computations that manipulate multiple, named, mutable objects, in the context of a non-strict, purely-functional language. The security of the encapsulation is assured by the type system, using parametricity. The same framework is also used to handle input/output operations (state changes on the external world) and calls to C.

[1]  John Launchbury,et al.  Structuring depth-first search algorithms in Haskell , 1995, POPL '95.

[2]  Philip Wadler,et al.  Comprehending monads , 1990, LISP and Functional Programming.

[3]  Keshav Pingali,et al.  I-structures: data structures for parallel computing , 1986, Graph Reduction.

[4]  Eugenio Moggi,et al.  Computational lambda-calculus and monads , 1989, [1989] Proceedings. Fourth Annual Symposium on Logic in Computer Science.

[5]  Simon L. Peyton Jones,et al.  The Implementation of Functional Programming Languages , 1987 .

[6]  Robin Milner,et al.  Definition of standard ML , 1990 .

[7]  John Launchbury,et al.  Unboxed values as first class citizens , 1991 .

[8]  Simon L. Peyton Jones,et al.  Imperative functional programming , 1993, POPL '93.

[9]  Vipin Swarup,et al.  Assignments for Applicative Languages , 1991, FPCA.

[10]  Simon L. Peyton Jones,et al.  Implementing lazy functional languages on stock hardware: the Spineless Tagless G-machine , 1992, Journal of Functional Programming.

[11]  Paul Hudak,et al.  Call by name, assignment, and the lambda calculus , 1993, POPL '93.

[12]  Simon L. Peyton Jones,et al.  Unboxed Values as First Class Citizens in a Non-Strict Functional Language , 1991, FPCA.

[13]  Bill Broyles Notes , 1907, The Classical Review.

[14]  Philip Wadler,et al.  Deforestation for Higher-Order Functions , 1992, Functional Programming.

[15]  Mads Tofte,et al.  Type Inference for Polymorphic References , 1990, Inf. Comput..

[16]  David K. Gifford,et al.  Integrating functional and imperative programming , 1986, LFP '86.

[17]  Assaf J. Kfoury,et al.  A direct algorithm for type inference in the rank-2 fragment of the second-order λ-calculus , 1994, LFP '94.

[18]  Jerzy Tiuryn,et al.  Type Reconstruction in Finite Rank Fragments of the Second-Order lambda-Calculus , 1992, Inf. Comput..

[19]  Wei-Ngan Chin,et al.  Automatic methods for program transformation , 1990 .

[20]  Peter W. O'Hearn,et al.  Relational parametricity and local variables , 1993, POPL '93.

[21]  Simon L. Peyton Jones,et al.  Lazy functional state threads , 1994, PLDI '94.

[22]  Uday S. Reddy,et al.  Imperative functional programming , 1996, CSUR.

[23]  John Hughes,et al.  Why Functional Programming Matters , 1989, Comput. J..

[24]  John H. Reppy,et al.  CML: A Higher-Order Concurrent Language , 1991, PLDI.

[25]  Philip Wadler,et al.  Comprehending monads , 1990, Mathematical Structures in Computer Science.

[26]  Carl Ponder,et al.  Are applicative languages inefficient? , 1988, SIGP.

[27]  Simon Peyton Jones,et al.  The Implementation of Functional Programming Languages (Prentice-hall International Series in Computer Science) , 1987 .

[28]  John C. Mitchell,et al.  Second-Order Logical Relations (Extended Abstract) , 1985, Logic of Programs.

[29]  Lennart Augustsson,et al.  Functional Pearl: On generating unique names , 1994, Journal of Functional Programming.

[30]  Nancy McCracken,et al.  The Typechecking of Programs with Implicit Type Structure , 1984, Semantics of Data Types.

[31]  Philip Wadler,et al.  The essence of functional programming , 1992, POPL '92.

[32]  Simon L. Peyton Jones,et al.  A short cut to deforestation , 1993, FPCA '93.

[33]  Erik Barendsen,et al.  Conventional and Uniqueness Typing in Graph Rewrite Systems , 1993, FSTTCS.

[34]  Arvind,et al.  M-Structures: Extending a Parallel, Non-strict, Functional Language with State , 1991, FPCA.

[35]  David A. Schmidt Detecting global variables in denotational specifications , 1985, TOPL.

[36]  Cordelia V. Hall Using Hindley-Milner type inference to optimise list representation , 1994, LFP '94.

[37]  Philip Wadler,et al.  Deforestation: Transforming Programs to Eliminate Trees , 1990, Theor. Comput. Sci..