Default Disambiguation in Online Parsers
summary
An editor prototype uses incremental parsing plus invisible language boxes to detect when an embedded language (Java, PHP, Lua, SQL) is being typed and automatically insert or remove boxes by scanning backward from a parse error and running the embedded language parser. Three heuristics (path, stack, line) generate candidates; evaluation over ~5,000 randomized edits yields 97% acceptable outcomes, 66% full-box inserts, 20.3% incorrect inserts and 0.8% failures, showing the approach works well but still makes some mistakes.
AI-written summary · about
chapters (12)
- 0:00Introduction
- 1:55Why do we need it
- 5:07Language Boxes
- 6:09Can we automate this
- 9:07Heuristics
- 10:30Ranking
- 11:15In Action
- 14:45Evaluation
- 17:47Past heuristic
- 18:23Stick heuristic
- 19:02Line heuristic
- 19:42Conclusion
related talks
26mDesign a new language in JS: from zero to autocomplete
15mSyntactic Completions with Material Obligations
20mAn Approach to Generate Text-Based IDEs for Syntax Correction based on Syntax Specification
27mExecution vs. Parse-Based Language Servers
10mData-centric disambiguation for data transformation with programming-by-example
27mParsing, Compiling, and Static Metaprogramming
25mText files full of punctuation? There must be a better way to code.
01h 06mOn-The-Fly Verification via Incremental, Interactive Abstract Interpretation wi...
