HomeFreeBSD

diff: Fix --expand-tabs and --side-by-side.

Description

diff: Fix --expand-tabs and --side-by-side.

  • Overhaul column width and padding calculation.
  • Rewrite print_space() so it is now a) correct and b) understandable.
  • Rewrite tab expansion in fetch() for the same reason.

This brings us in line with GNU diff for all cases I could think of.

Sponsored by: Klara, Inc.
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D44014

(cherry picked from commit 53de23f4d140becc3166e87665b0064f215a220e)

diff: Bump manual page date.

Sponsored by: Klara, Inc.

(cherry picked from commit 312b1076c6b0aff9bbcaff058b93385eaf607685)

Details

Provenance
desAuthored on Feb 26 2024, 6:08 PM
Reviewer
imp
Differential Revision
D44014: diff: Fix --expand-tabs and --side-by-side.
Parents
rG07de733b1f55: MFC: liblzma: don't export lzma_lz_decoder_uncompressed
Branches
Unknown
Tags
Unknown