The grand strategy of Ruby Parser
summary
Ruby replaces Bison with Lrama (an LR parser generator written in Ruby) to generate CRuby parsers since 3.3, adds an error‑tolerant recovery using CPCT+, and removes the single large Node union so AST nodes are expanded and memory optimized in master. Lrama is RBS typeable and won a Fukuoka award. Remaining portability blockers are two C dependencies, ID and rb_str_vcatf. Roadmap targets: LSP-friendly locations, a universal parser backend, and language‑agnostic action code generation.
AI-written summary · about
chapters (10)
- 0:00Introduction and speaker background
- 1:06Ruby parser basics and LALR parsers
- 2:28Grand strategy goals for Ruby parser
- 8:22Parser generators vs handwritten parsers
- 11:56Milestones for LSP and universal parser
- 14:04Challenges with parse.y maintenance
- 20:31Progress and team growth
- 21:14Universal parser and dependencies
- 24:28Future of universal parser design
- 25:54Summary and Ruby 3.4 plans
related talks
29mHow does Lrama make the Ruby parser grammar G.O.A.T.?
26mLiberating Ruby's Parser from Lexer Hacks
28mMaking the RBS Parser Faster
32mParsing Ruby
48mRapid Programming Language Prototypes with Ruby RACC
46mGrammar a BNF like Ruby DSL Parsing
40mThe Future of Understanding Ruby Code
37mRuby Parser In IRB 20th Anniversary...Now Let Time Resume
