High-Fidelity Metaprogramming with Separator Syntax Trees
summary
Claims a lightweight way to keep source layout by augmenting AST nodes with string lists of separators so formatting and comments round subtrees survive rewriting; implemented as separator syntax trees inside Rascal backed by prior C++ AST work and Eclipse C++ tooling; builds an encapsulate-field refactoring for C++ that preserves comments and placement and parses back to valid C++; limitations include operator‑precedence artifacts, suboptimal indentation strategy, and repeated parsing of right‑hand patterns.
AI-written summary · about
chapters (10)
- 0:00Start
- 0:29Metaprogramming
- 1:31Syntax Trees
- 3:10Rewriting with CSTS
- 13:23Rewriting with SSTS
- 14:58List substitution intricacies
- 16:29Evaluation
- 17:47Encapsulate Field (C++)
- 20:56Questions
- 21:28Discussion and limitations
related talks
27mAST Meta-programming
29mMy Little Parser: Tooling is Magic
22mImproving Swift Tools with libSyntax
29mTrieste: A C++ DSL for Flexible Tree Rewriting (Tool paper)
50mSyntaxation
01h 01mExpressive Compile Time Parsers
25mIncremental Parsing with emacs-tree-sitter
01h 27mBoost.Parser (Part 1 of 2) - A Parser Combinator Library for C++
