| Paul Hudak. Mutable abstract datatypes-or- How to have your state and munge it too. Tech. Rep. YALEU/DCS/RR-914 (1992), Yale University, Department of Computer Science. May 1993 revision. |
....embedded in another term. State in [16] is dynamic, i.e. it consists of a heap with dynamically created references. Figure 4 shows an implementation of local statetransformers with dynamic state. This is to my knowledge the first fully formal treatment of this class of statetransformers, even if [4] and [5] contain similar informal proposals. State is represented as a polymorphic function from type State = all a. Name a a type ST a = all b. a State b) State b Monadic Operators: State Based Operators: return : a ST a newref : ST (Name a) ST a (a ST ....
P. Hudak and D. Rabin. Mutable abstract datatypes -- or -- how to have your state and munge it too. Research Report YALEU/DCS/RR-914, Yale University, Department of Computer Science, July 1992.
....previously set suffix links become obsolete by updating the tree. However, the suffix tree undergoing a sequence of updates satisfies the condition of singlethreadedness. No copy of an intermediate tree is used elsewhere in the program. Thus, recent ideas on monads [Wad92] or mutable data types [Hud93] for functional programming languages incorporating local, in place updates, apply to this case. A change of the data structure becomes necessary. The tree is represented by mutable arrays, closely resembling our imperative implementation of ukk and mcc. In this way, we have recently achieved a ....
P. Hudak. Mutable Abstract Data Types or How to Have Your State and Munge It Too. Report, YALEU/DCS/RR-914, Yale University, Dep. of Computer Science, 1993.
....implemented using destructive updating. We will call such ADTs linear. The main advantage of this approach is that no extension of a conventional functional language is required; only a special implementation of the ADT is required. Hudak is investigating the general implementation of linear ADTs [10]. The next section describes our own research with a linear ADT. 5 A linear ADT This section describes our own ideas for a linear abstract data type. The ADT described has been inspired by Wadler s ideas on monads [15, 17] The linear ADT allows replace operations to be implemented using ....
P Hudak. Mutable abstract datatypes or how to have your state and munge it. Draft Summary, July 1992.
....operations given in the specification and that of the implementation. These kind of problems also appear in the imperative implementation of data types. For monadic data structures, there exist techniques which mechanically relate the monadic and non monadic implementations of a given type (see [8]) For uniqueness types, the conversion techniques are very easy because there is only a trivial change in the signature, and the compiler can infer the uniqueness types. 7 Conclusion We have presented a proposal for a course on data structures based on the functional paradigm. One of the claims ....
P. Hudak. Mutable abstract datatypes or How to have your state and munge it too. Technical Report YALEU/DCS/RR-914, Yale University, 1993.
....of scientific or numeric programs. One of these projects in particular seems to have potential in the area of building systems for implementing general purpose parallel programs. Hudak designed a construct for functional programming languages called a Mutable Abstract Datatype (MAD) Hud92] based on a functional construct called a Monad. This group has also developed a parallel programming model based on these constructs that allows explicitly parallel programs to be written that operate on these functional mutable data types [JH93] This model uses a programming structure that is ....
P. Hudak. Mutable abstract datatypes-or- how to have your state and munge it too. Technical Report YALEU/DCS/RR-914, Yale University, 1992.
....to work with the closure typing system because it provides a direct relationship between types and actual structure of objects and a simpler theoretical framework to deal with. A different approach to integrate imperative and (lazy) functional programming has been the focus of many recent papers [5, 20, 23, 17, 3, 18, 7, 9]. These papers attempt to introduce assignments into a functional language without destroying its strong functional properties (e.g. confluence and referential transparency) To preserve these properties, they ensure that assignments in a program are single threaded [19] by means of type ....
.... properties (e.g. confluence and referential transparency) To preserve these properties, they ensure that assignments in a program are single threaded [19] by means of type systems [5, 20, 23] reduction rules [17] dataflow analysis [3, 18] or data abstraction and monadic function composition [7, 9]. Side effect analysis using regions, such as ours, is orthogonal to the techniques given in these papers and such analysis could be used to make these languages or type systems more permissive. Our system inherits the properties of the underlying imperative kernel and simply provides a sound ....
P. Hudak and D. Rabin. Mutable abstract datatypes - or - how to have your state and munge it too. Technical Report YALEU/DCS/RR-914, Yale University, Department of Computer Science, July 1992.
....T . Proof: By applying the translation scheme to a generic axiom of each kind, then using equational reasoning to unfold the monadic encapsulation on each side and reduce them to equivalent terms. A proof for one of the three axioms is given in Appendix B. 5 GRS Operational Semantics In [7] we informally defined: Definition 5 A mutable ADT, or MADT, is any ADT whose operational semantics permits in place update (i.e. destructive reuse) of the type of interest, while still retaining confluence. We will now make this definition more precise. To do so, we need an operational ....
P. Hudak. Mutable abstract datatypes -- or -- how to have your state and munge it too. Research Report YALEU/DCS/RR-914, Yale University, Department of Computer Science, December 1992.
....state a powerful abstraction, even if it is easily misused. The traditional alternative offered by functional programming is to make state explicit. The resulting plumbing problems can be ameliorated by hiding the state parameter using monads [20] or by using continuation passing style [10]. Wadler, for example, uses the monad technique in [22] to present pure functional programming as an alternative to impure programming with assignments. Monads are indeed successful in eliminating explicit mention of state arguments, but they still require a centralized definition of state. We ....
P. Hudak and D. Rabin. Mutable abstract datatypes -- or -- how to have your state and munge it too. Research Report YALEU/DCS/RR-914, Yale University, Department of Computer Science, July 1992.
No context found.
Paul Hudak. Mutable abstract datatypes-or- How to have your state and munge it too. Tech. Rep. YALEU/DCS/RR-914 (1992), Yale University, Department of Computer Science. May 1993 revision.
Online articles have much greater impact More about CiteSeer.IST Add search form to your site Submit documents Feedback
CiteSeer.IST - Copyright Penn State and NEC