You are viewing content intended for a different location. This may affect your ability to shop online.

Our systems are now restored following recent technical disruption, and we’re working hard to catch up on publishing. We apologise for the inconvenience caused. Find out more

Recommended product

Popular links

Popular links


Control Structures for Programming Languages

Control Structures for Programming Languages

Control Structures for Programming Languages

From GOTO to Algebraic Effects
Author:
Xavier Leroy, Collège de France, Paris
Published:
December 2026
Availability:
Available
Format:
Hardback
ISBN:
9781009767514

Looking for an inspection copy?

This title is not currently available for inspection.

    An exploration of the design space and development of programming languages from the perspective of control structures: the language mechanisms that enable programs to control their execution flows. Starting with the 'goto' jumps of early programming languages and the emergence of structured programming in the 1960s, this book explores advanced control structures for imperative languages such as generators and coroutines, then develops alternate views of control in functional languages, first as continuations and their control operators, then as algebraic effects and effect handlers, as found in the OCaml language. Blending history, code examples, and theory, it offers advanced students, researchers, and programming language enthusiasts an original, comparative perspective on programming languages, as well as an extensive introduction to algebraic effects and other contemporary research topics.

    • Provides one of the first comprehensive accounts of effect handlers and the underlying theory of algebraic effects
    • Gives an original comparative and historical perspective on programming languages
    • Shows many well-chosen code samples that illustrate concretely and concisely the concepts introduced in the book

    Reviews & endorsements

    'A story about how our ways of telling computers what should happen, when have evolved over three quarters of a century, told by a master programming language designer and implementer.' Benjamin Pierce, University of Pennsylvania

    'Control structures are the nervous system of a programming language: they determine how computations are executed, interrupted, resumed, and interwoven. In this book, Xavier Leroy, the architect of the OCaml programming language, gives a comprehensive account of control structures, from the historic 'goto' statement to the state-of-the-art algebraic effects and handlers. Theory, practice and concrete examples are masterfully combined into a whole that will be valuable both to implementors of programming languages and to programmers who want to better understand the tools they use every day.' Andrej Bauer, University of Ljubljana

    Product details

    • Published: November 2026
    • Format: Adobe eBook Reader
    • ISBN: 9781009767507
    • Length: 0 pages
    • Availability: Not yet published - available from November 2026

    Table of Contents

    • Preface
    • Introduction
    • Part I. Control Structures for Imperative Languages:
    • 1. Early programming languages
    • 2. Structured programming
    • 3. Non-local control: Subroutines, procedures, functions
    • 4. Control inversion: Iterators, generators, coroutines
    • Part II. Control Operators for Functional Languages:
    • 5. Functional languages
    • 6. Continuations and the CPS transformation
    • 7. Programming with continuations
    • 8. Control operators
    • Part III. From Exceptions to Algebraic Effects and Handlers:
    • 9. Exceptions
    • 10. Effect handlers for user-defined effects
    • 11. Monads
    • 12. Algebraic effects
    • Part IV. Reasoning about Control and Effects:
    • 13. Type and effect systems
    • 14. Hoare logic for control structures
    • 15. Separation logic for control operators
    • Bibliography
    • Index.

    Author

    Xavier Leroy , Collège de France, Paris

    Xavier Leroy is Professor of Software Sciences at Collège de France. He is known for his work on OCaml, a popular functional programming language, and CompCert, the first formally verified C compiler. He is a member of the French Academy of Sciences and a Fellow of the ACM.