Authors
Nicolas Wu, Tom Schrijvers
Publication date
2015/6/9
Book
International Conference on Mathematics of Program Construction
Pages
302-322
Publisher
Springer International Publishing
Description
Algebraic effect handlers are a recently popular approach for modelling side-effects that separates the syntax and semantics of effectful operations. The shape of syntax is captured by functors, and free monads over these functors denote syntax trees. The semantics is captured by algebras, and effect handlers pass these over the syntax trees to interpret them into a semantic domain.
This approach is inherently modular: different functors can be composed to make trees with richer structure. Such trees are interpreted by applying several handlers in sequence, each removing the syntactic constructs it recognizes. Unfortunately, the construction and traversal of intermediate trees is painfully inefficient and has hindered the adoption of the handler approach.
This paper explains how a sequence of handlers can be fused into one, so that multiple tree traversals can be reduced to a single one and …
Total citations
2015201620172018201920202021202220232563589105
Scholar articles
N Wu, T Schrijvers - International Conference on Mathematics of Program …, 2015