April 22 – 27 , 2018, Dagstuhl Seminar 18172

Algebraic Effect Handlers go Mainstream


Sivaramakrishnan Krishnamoorthy Chandrasekaran (University of Cambridge, GB)
Daan Leijen (Microsoft Research – Redmond, US)
Matija Pretnar (University of Ljubljana, SI)
Tom Schrijvers (KU Leuven, BE)

For support, please contact

Dagstuhl Service Team


List of Participants
Shared Documents
Dagstuhl Seminar Schedule (Upload here)

(Use seminar number and access code to log in)


Languages like C#, C++, or JavaScript support complex control flow statements like exception handling, iterators (yield), and even asynchrony (asyncawait) through special extensions. For exceptions, the runtime needs to be extended with exception handling stack frames. For iterators and asynchrony, the situation is more involved, as the compiler needs to turn regular code into stack restoring state machines. Furthermore, these features need to interact as expected, e.g. finally blocks must not be forgotten in the state machines for iterators. And all of this work needs to be done again for the next control flow abstraction that comes along.

Or we can use algebraic effect handlers! This single mechanism generalizes all the control flow abstractions listed above and more, composes freely, has simple operational semantics, and can be efficiently compiled, since there is just one mechanism that needs to be supported well. Handlers allow programmers to keep the code in direct-style, which is easy to reason about, and empower library writers to implement various high-level abstractions without special extensions.

The idea of algebraic effects handlers has already been experimented with in the form of small research languages and libraries in several mainstream languages, including OCaml, Haskell, Clojure, and Scala. The next step, and the aim of this seminar, is to seriously consider adoption by mainstream languages including both functional languages such as OCaml or Haskell, as well as languages like JavaScript and the JVM and .NET ecosystems.

Topics of the seminar will include:

  • Presenting ways algebraic effect handlers solve current issues and express legacy abstractions in mainstream programming languages.
  • Discussing ways of introducing handlers into existing mainstream languages and ecosystems that have grown around them, and exploring ways of presenting handlers to the programmer.
  • Analysing issues that have surfaced in initial prototypes such as interaction with other language features, runtime performance, or concurrent execution, and surveying recent theoretical developments.
  • Showcasing programs such as a high performance web server or a user interface library, which illustrate the benefit of handler-oriented architecture.

  Creative Commons BY 3.0 DE
  Daan Leijen, Matija Pretnar, Tom Schrijvers, and KC Sivaramakrishnan

Related Dagstuhl Seminar


  • Programming Languages / Compiler
  • Semantics / Formal Methods


  • Algebraic effect handlers
  • Implementation techniques
  • Programming languages
  • Programming abstractions

Book exhibition

Books from the participants of the current Seminar 

Book exhibition in the library, ground floor, during the seminar week.


In the series Dagstuhl Reports each Dagstuhl Seminar and Dagstuhl Perspectives Workshop is documented. The seminar organizers, in cooperation with the collector, prepare a report that includes contributions from the participants' talks together with a summary of the seminar.


Download overview leaflet (PDF).


Furthermore, a comprehensive peer-reviewed collection of research papers can be published in the series Dagstuhl Follow-Ups.

Dagstuhl's Impact

Please inform us when a publication was published as a result from your seminar. These publications are listed in the category Dagstuhl's Impact and are presented on a special shelf on the ground floor of the library.

NSF young researcher support