Invertible Programs
summary
parserz v0.2 claims a working library that runs parsers both ways so code converts to AST and prints back after transformations, with a single-line public interface and zero dependencies. it supports state and error channels, emits compiler-style positions, can generate a BNF-like description, and enables automatic source migration of stored programs. examples include turning program text into structures and back and even getting a web client for free from a server parser.
AI-written summary · about
chapters (17)
- 0:00Introduction
- 1:15Background
- 3:44Invertible Programs
- 9:30Parsers
- 12:44Application of invertible
- 13:56One line of code
- 15:28Grammar
- 17:26Free encoding
- 18:55Functions
- 21:44Example
- 26:13Parser
- 27:14Comments
- 29:45Stateful
- 30:52Awesome Scholar
- 31:42Why Invertible
- 34:17Generality
- 37:59Questions
related talks
15mFast & Easy ASTs for Flexible Embedded Interpreters
29mMy Little Parser: Tooling is Magic
44mPretty Parsing
44mLet's talk about transpilers
27mAST Meta-programming
44mJavaScript AST programming: Introduction and beyond
01h 48mBoost.Parser (Part 2 of 2) - A Parser Combinator Library for C++
31mTime flies like an arrow, fruit flies like a banana
