Source-order line diff
Compares rows in their current position. A moved function can appear as one large deletion followed by one large insertion.
Concept and worked evidence
A semantic code diff uses program structure to reduce misleading delete-and-insert noise. AlignDiff pairs related functions, classes, methods, and other supported structures before showing detailed line changes.

Definition
AlignDiff is structure-aware rather than a proof of behavioural equivalence. It parses supported source files, identifies named structures, proposes pairs, and then calculates the detailed text changes inside each pair.
That distinction matters: a structural match can show that two functions are likely counterparts after a move or rename, but it cannot prove that the refactor preserves runtime behaviour.
Line diff versus structure-aware diff
Compares rows in their current position. A moved function can appear as one large deletion followed by one large insertion.
Pairs likely counterparts first. Movement remains visible, while edits inside the moved function can be reviewed in the same horizontal lane.
When it is useful
Separate relocation from changes made inside the function.
Inspect a likely rename without losing the corresponding body.
Reduce navigation cost when many blocks move in the same pull request.
Current boundaries
.ts TypeScript.Continue exploring