3 ms·
I think the only useful way to implement AST-level diff/merge for non-trivial codebases would require the compiler to provide the parsed AST, since per-file AST
by jakeinspace 5y ago
I think the only useful way to implement AST-level diff/merge for non-trivial codebases would require the compiler to provide the parsed AST, since per-file ASTs would lack a lot of context. You could also ask the user to provide a separate file or files that describe the code topology, but why bother when the compiler can spit out an AST itself? A diff tool which targets a few of the bigger build systems (CMake, Maven, Gradle) and compilers might work, and could worry about small build environments after gaining momentum.