freebsd-dev/usr.bin/diff3
Tom Jones 2184ca3f19 diff3: Clean up printing of ranges for edscript output
Replace the edscript code that tracked and printed lines using byte
offsets with code that can work from line offsets.

This tidies up the reduces duplication in the edscript output code. It
also fixes the usage of the de struct so that it only tracks diffs as
line offsets rather than the usage changing from line offsets to byte
offsets during the lifetime of diff3.

Large files with large numbers of ranges will probably suffer in
performance here, but as we don't use diff3 yet this isn't a regression.
Include a warning for future hackers so they have a place to start
hacking from.

Reviewed by:	pstef
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D34941
2022-04-19 14:51:18 +01:00
..
tests diff3: allow diff3 ed scripts to generate deletions 2022-04-15 15:00:59 +01:00
diff3.1 diff3: document and test -T 2021-08-25 18:20:59 +02:00
diff3.c diff3: Clean up printing of ranges for edscript output 2022-04-19 14:51:18 +01:00
Makefile Add HAS_TESTS to all Makefiles that are currently using the 2017-08-02 08:50:42 +00:00