Professor GRAHAM HUTTON GRAHAM.HUTTON@NOTTINGHAM.AC.UK
Professor of Computer Science
Monadic parser combinators
Hutton, Graham; Meijer, Erik
Authors
Erik Meijer
Abstract
In functional programming, a popular approach to building recursive descent parsers is to model parsers as functions, and to define higher-order functions (or combinators) that implement grammar constructions such as sequencing, choice, and repetition. Such parsers form an instance of a monad, an algebraic structure from mathematics that has proved useful for addressing a number of computational problems. The purpose of this report is to provide a step-by-step tutorial on the monadic approach to building functional parsers, and to explain some of the benefits that result from exploiting monads. No prior knowledge of parser combinators or of monads is assumed. Indeed, this report can also be viewed as a first introduction to the use of monads in programming.
Citation
Hutton, G., & Meijer, E. (1996). Monadic parser combinators. School of Computer Science and IT
Book Type | Monograph |
---|---|
Publication Date | Jan 1, 1996 |
Deposit Date | Oct 26, 2005 |
Publicly Available Date | Oct 9, 2007 |
Peer Reviewed | Not Peer Reviewed |
Public URL | https://nottingham-repository.worktribe.com/output/1024440 |
Files
monparsing.pdf
(254 Kb)
PDF
You might also like
Monadic compiler calculation (functional pearl)
(2022)
Journal Article
Calculating dependently-typed compilers (functional pearl)
(2021)
Journal Article
Calculating correct compilers II: Return of the register machines
(2020)
Journal Article
Liquidate your assets: reasoning about resource usage in liquid Haskell
(2019)
Journal Article
Call-by-need is clairvoyant call-by-value
(2019)
Journal Article
Downloadable Citations
About Repository@Nottingham
Administrator e-mail: digital-library-support@nottingham.ac.uk
This application uses the following open-source libraries:
SheetJS Community Edition
Apache License Version 2.0 (http://www.apache.org/licenses/)
PDF.js
Apache License Version 2.0 (http://www.apache.org/licenses/)
Font Awesome
SIL OFL 1.1 (http://scripts.sil.org/OFL)
MIT License (http://opensource.org/licenses/mit-license.html)
CC BY 3.0 ( http://creativecommons.org/licenses/by/3.0/)
Powered by Worktribe © 2024
Advanced Search