Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Diff

A diff is the textual difference between two versions of code. It represents the added, removed and modified lines.

Diffs are a staple of CVS systems. They are important when reviewing a PR, as they represent only the changed lines.

Diffs are used to identify modifications, although they fail at identifying exhaustively all impacts in the code.

Diff is also the name of the software that calculates the difference between two files.

A diff is not always unique: two files’ difference may be represented by two distinct diffs, or more.

Documentation

See Also