# Functions
NewFileDiffReader returns a new FileDiffReader that reads a file unified diff.
NewHunksReader returns a new HunksReader that reads unified diff hunks from r.
NewMultiFileDiffReader returns a new MultiFileDiffReader that reads a multi-file unified diff from r.
ParseFileDiff parses a file unified diff.
ParseHunks parses hunks from a unified diff.
ParseMultiFileDiff parses a multi-file unified diff.
PrintFileDiff prints a FileDiff in unified diff format.
PrintHunks prints diff hunks in unified diff format.
PrintMultiFileDiff prints a multi-file diff in unified diff format.
# Variables
ErrBadFileHeader is when a file unified diff has a malformed file header (i.e., the lines that begin with "---" and "+++").
ErrBadOnlyInMessage is when a file have a malformed `only in` message Should be in format `Only in {source}: {filename}`.
ErrExtendedHeadersEOF is when an EOF was encountered while reading extended file headers, which means that there were no ---/+++ headers encountered before hunks (if any) began.
No description provided by the author
ErrNoFileHeader is when a file unified diff has no file header (i.e., the lines that begin with "---" and "+++").
ErrNoHunkHeader indicates that a unified diff hunk header was expected but not found during parsing.
# Structs
ErrBadHunkHeader indicates that a malformed unified diff hunk header was encountered during parsing.
ErrBadHunkLine is when a line not beginning with ' ', '-', '+', or '\' is encountered while reading a hunk.
A FileDiff represents a unified diff for a single file.
FileDiffReader reads a unified file diff.
A Hunk represents a series of changes (additions or deletions) in a file's unified diff.
A HunksReader reads hunks from a unified diff.
MultiFileDiffReader reads a multi-file unified diff.
A ParseError is a description of a unified diff syntax error.
A Stat is a diff stat that represents the number of lines added/changed/deleted.
# Type aliases
OverflowError is returned when we have overflowed into the start of the next file while reading extended headers.