@vindex diff-update-on-the-fly
You can edit a Diff mode buffer like any other buffer. (If it is
- read-only, you need to make it writable first. @xref{Misc Buffer}.)
- Whenever you change a hunk, Diff mode attempts to automatically
- correct the line numbers in the hunk headers, to ensure that the patch
- remains correct. To disable automatic line number correction,
- change the variable @code{diff-update-on-the-fly} to @code{nil}.
-
- Diff mode treats each hunk as an error message, similar to
- Compilation mode. Thus, you can use commands such as @kbd{M-g M-n} to
- visit the corresponding source locations. @xref{Compilation Mode}.
+ read-only, you need to make it writable first; see @ref{Misc Buffer}.)
+ Whenever you edit a hunk, Diff mode attempts to automatically correct
+ the line numbers in the hunk headers, to ensure that the patch remains
+ correct, and could still be applied by @command{patch}. To disable
+ automatic line number correction, change the variable
+ @code{diff-update-on-the-fly} to @code{nil}.
+
+ Diff mode arranges for hunks to be treated as compiler error
-messages by @kbd{C-x `} and other commands that handle error messages
++messages by @kbd{M-g M-n} and other commands that handle error messages
+ (@pxref{Compilation Mode}). Thus, you can use the compilation-mode
+ commands to visit the corresponding source locations.
In addition, Diff mode provides the following commands to navigate,
manipulate and apply parts of patches: