Boost.Parser (Part 2 of 2) - A Parser Combinator Library for C++
summary
Boost.Parser is a Boost candidate library for C++17+ that combines Spirit2 and X3 ideas to produce a parser-combinator library with concrete features: Boost.Parser provides typed rules (no attribute destructuring across rule boundaries), built‑in expectation‑point diagnostics (throws exceptions with file/line/column and caret), Unicode-aware parsing for char/char32_t (but no normalization), a JSON example with max nesting default 512, callback parsing for SAX-style tests, trace output to stdout, search/replace adapters, and planned optimizations like packrat caching. It compiles and runs; diagnostics and debugging aids work as shown.
AI-written summary · about
chapters (11)
- 0:00Introduction
- 0:23Rules in Boost.Parser
- 11:33Higher order parsers
- 20:00Directives in parsers
- 28:05Unicode support
- 41:06Diagnostics and error reporting
- 56:07Debugging tools
- 1:01:11Debugging semantic actions
- 1:14:31Extended JSON example
- 1:32:07Callback parsing
- 1:37:30Future work and Q&A
related talks
01h 01mUsing Spirit X3 to Write Parsers
41mParser Combinators
26mParser Combinators in Swift
53mUnderstanding parser combinators: a deep dive
58mParsing in C# from first principles
15mStaged Selective Parser Combinators
52mBuilding a parser in C#, from first principles
01h 01mExpressive Compile Time Parsers
