### General Terms

"... Monads as an organizing principle for programming and semantics are notoriously difficult to grasp, yet they are a central and powerful abstraction in Haskell. This paper introduces a domain-specific language, MonadLab, that simplifies the construction of monads, and describes its implementation in ..."

Abstract
- Add to MetaCart

(Show Context)
Monads as an organizing principle for programming and semantics are notoriously difficult to grasp, yet they are a central and powerful abstraction in Haskell. This paper introduces a domain-specific language, MonadLab, that simplifies the construction of monads, and describes its implementation in Template Haskell. MonadLab makes monad construction truly first class, meaning that arcane theoretical issues with respect to monad transformers are completely hidden from the programmer. The motivation behind the design of MonadLab is to make monadic programming in Haskell simpler while providing a tool for non-Haskell experts that will assist them in understanding this powerful abstraction.

### A Logical View of Effects

"... Despite their invaluable contribution to the programming language community, monads as a foundation for the study of effects have three problems: they make it difficult to combine effects; they enforce sequentialization of computations by the syntax; they prohibit effect-free evaluations from invoki ..."

Abstract
- Add to MetaCart

Despite their invaluable contribution to the programming language community, monads as a foundation for the study of effects have three problems: they make it difficult to combine effects; they enforce sequentialization of computations by the syntax; they prohibit effect-free evaluations from invoking e#ectful computations. Building on the judgmental formulation and the possible worlds interpretation of modal logic, we propose a logical analysis of effects based upon the view monads are not identified with effects. Our analysis leads to a language called # # which distinguishes between control e#ects and world e#ects, enforces sequentialization of computations only by the semantics, and logically explains the invocation of computations from evaluations. # # also serves as a unified framework for studying Haskell and ML, which have traditionally been studied separately.

### Combining Continuations with Other Effects

"... A fundamental question, in modelling computational effects, is how to give a unified semantic account of modularity, i.e., a mathematical theory that supports the various combinations one naturally makes of computational effects such as exceptions, side-effects, interactive input/output, nondetermin ..."

Abstract
- Add to MetaCart

A fundamental question, in modelling computational effects, is how to give a unified semantic account of modularity, i.e., a mathematical theory that supports the various combinations one naturally makes of computational effects such as exceptions, side-effects, interactive input/output, nondeterminism, and, particularly for this workshop, continuations [2, 3, 5]. We have begun to give such an account over recent years for all of these effects other than continuations [8], describing the sum and the tensor, or commutative combination, of effects, starting from Eugenio Moggi's proposal to use monads to give semantics for each individual effect [15]. That has yielded the most commonly used combinations of the various effects. Here, we extend our account to include continuations. We consider three distinct ways in which continuations combine with the other effects: sum, tensor, and by applying the continuations monad transformer C(-); we analyse each of these in the following three Detections. We did not...

### FUNCTIONAL PEARL Data types àlacarte

"... This paper describes a technique for assembling both data types and functions from isolated individual components. We also explore how the same technology can be used to combine free monads and, as a result, structure Haskell’s monolithic IO monad. 1 ..."

Abstract
- Add to MetaCart

(Show Context)
This paper describes a technique for assembling both data types and functions from isolated individual components. We also explore how the same technology can be used to combine free monads and, as a result, structure Haskell’s monolithic IO monad. 1

### Refactoring for Comprehension

"... Functional programming is well suited for equational reasoning on programs. In this paper, we are trying to use this capability for program comprehension purposes. Specifically, in a program understanding process, higher-order operators can work like abstract schemes in which we can fit formal speci ..."

Abstract
- Add to MetaCart

(Show Context)
Functional programming is well suited for equational reasoning on programs. In this paper, we are trying to use this capability for program comprehension purposes. Specifically, in a program understanding process, higher-order operators can work like abstract schemes in which we can fit formal specifications calculated from the source code. Such specifications are calculated by a transformational process which we call reverse program calculation that operates on both notations: pointwise and pointfree. Once a specification matches an abstract schema, a new refactoring phase leading to a clearer source code takes place. At the same time, an unambiguous behavioural understanding is reached because we give a mathematical description of the abstract schemes. To provide a more complete and realistic perspective of the approach, we use recursive operators that can handle side effects.

### Modular Modelling with Monads

, 2005

"... monads, which are used to model diverse computational effects (such as stateful computations, exceptional behaviour or non-determinism). This goes back to Moggi [6], and is for example used to great effect in the pure functional language Haskell [8, 11]. In this talk, we use the same technique to mo ..."

Abstract
- Add to MetaCart

(Show Context)
monads, which are used to model diverse computational effects (such as stateful computations, exceptional behaviour or non-determinism). This goes back to Moggi [6], and is for example used to great effect in the pure functional language Haskell [8, 11]. In this talk, we use the same technique to model computational effects in higher-order logic, and in particular the theorem prover Isabelle [7], thus shallowly embedding a small imperative language embedded shallow into Isabelle. The talk consists of three parts: we first recall the basic notions of monads, then show how the imperative language is built from three basic ingredients, and finally discuss the implementation. Monads A monad is the categorical modelling of an algebraic theory (that is, a set of operations and equations on them). One attraction of monads is that they come with a rich categorical model theory, giving a uniform treatment of both algebras and terms. The latter are given by the Kleisi category of a monad; this is where the computations modelled by the monad live. An adjunction

### Bimonadic Semantics for Basic Pattern Matching Calculi

, 2006

"... The pattern matching calculi introduced by the first author are a refinement of the λ-calculus that integrates mechanisms appropriate for fine-grained modelling of non-strict pattern matching. While related work in the literature only uses a single monad, typically Maybe, for matchings, we present a ..."

Abstract
- Add to MetaCart

The pattern matching calculi introduced by the first author are a refinement of the λ-calculus that integrates mechanisms appropriate for fine-grained modelling of non-strict pattern matching. While related work in the literature only uses a single monad, typically Maybe, for matchings, we present an axiomatic approach to semantics of these pattern matching calculi using two monads, one for expressions and one for matchings. Although these two monads only need to be relatively lightly coupled, this semantics implies soundness of all core PMC rules, and is a useful tool for exploration of the design space for pattern matching calculi. Using lifting and Maybe monads, we obtain standard Haskell semantics, and by adding another level of Maybe to both, we obtain a denotational semantics of the “matching failure as exceptions” approach of Erwig and Peyton Jones. Using list-like monads opens up interesting extensions in the direction of functional-logic programming. A short version of this report appears as [Kahl, Carette + 2006].

### Semantic Support for Model Composition

"... The essence of systems-level design is the need to integrate models representing different system facets to understand the impacts of local decisions on global requirements. Unfortunately, these models may be defined in disparate semantic systems making composition and integrated analysis challengi ..."

Abstract
- Add to MetaCart

(Show Context)
The essence of systems-level design is the need to integrate models representing different system facets to understand the impacts of local decisions on global requirements. Unfortunately, these models may be defined in disparate semantic systems making composition and integrated analysis challenging. As a part of the Rosetta systems-level design effort, a collection of mechanisms based on coalgebraic semantics has been defined to transform and compose models. Functors define mechanisms for moving models between specification domains; coproducts define mechanisms for composing multiple specifications; and translator functions define mechanisms for structurally compose specifications. Together these techniques provide specification composition support for integrating formal, systems-level analysis activities.