Grove: A Bidirectionally Typed Collaborative Structure Editor Calculus
Michael D. Adams, Eric Griffis, Thomas Porter, Sundara Vishnu Satish, Eric Zhao, Cyrus Omar
摘要
Version control systems typically rely on a patch language, heuristic patch synthesis algorithms like diff, and three-way merge algorithms. Standard patch languages and merge algorithms often fail to identify conflicts correctly when there are multiple edits to one line of code or code is relocated. This paper introduces Grove, a collaborative structure editor calculus that eliminates patch synthesis and three-way merge algorithms entirely. Instead, patches are derived directly from the log of the developer's edit actions and all edits commute, i.e. the repository state forms a commutative replicated data type (CmRDT). To handle conflicts that can arise due to code relocation, the core datatype in Grove is a labeled directed multi-graph with uniquely identified vertices and edges. All edits amount to edge insertion and deletion, with deletion being permanent. To support tree-based editing, we define a decomposition from graphs into groves, which are a set of syntax trees with conflicts-including local, relocation, and unicyclic relocation conflicts-represented explicitly using holes and references between trees. Finally, we define a type error localization system for groves that enjoys a totality property, i.e. all editor states in Grove are statically meaningful, so developers can use standard editor services while working to resolve these explicitly represented conflicts. The static semantics is defined as a bidirectional marking system in line with recent work, with gradual typing employed to handle situations where errors and conflicts prevent type determination. We then layer on a unification-based type inference system to opportunistically fill type holes and fail gracefully when no solution exists. We mechanize the metatheory of Grove using the Agda theorem prover. We implement these ideas as the Grove Workbench, which generates the necessary data structures and algorithms in OCaml given a syntax tree specification.
CCS Concepts: • Software and its engineering Ñ General programming languages; Syntax; Software configuration management and version control systems.
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper3
- Denicek: Computational Substrate for Document-Oriented End-User ProgrammingTomas Petricek, Jonathan EdwardsUIST 2025 · 被引用 2 次
- Direct Manipulation and Natural Language Programming, Together at Last?Parker Ziegler, David Minh-Duy Cao, Justin Lubin, Sarah E. ChasinsOOPSLA 2026
- Interactive Data Analysis with Lively Typed TablesAlexander Bandukwala, Cyrus OmarOOPSLA 2026
它引用的顶会 Paper2
相关 Paper
- Type-Checking CRDT ConvergenceGeorge Zakhour, Pascal Weisenburger, Guido SalvaneschiPLDI 2023 · 被引用 16 次
- Grove: a Separation-Logic Library for Verifying Distributed SystemsUpamanyu Sharma, Ralf Jung, Joseph Tassarotti, M. Frans Kaashoek 等SOSP 2023 · 被引用 18 次
- On the Correctness of Software MergeAkira Mori, Masatomo HashimotoASE 2025
- Composing CRDTs Convergent by ConstructionAlexander Städing Dominguez, George Zakhour, Pascal Weisenburger, Guido SalvaneschiOOPSLA 2026
- Merge Conflict Resolution: Classification or Generation?Jinhao Dong, Qihao Zhu, Zeyu Sun, Yiling Lou 等ASE 2023 · 被引用 8 次
