diff: convert --check to use a hunk callback
commit75ab76306cb97b223b29e9460a9589cfd099213e
authorJeff King <peff@peff.net>
Fri, 2 Nov 2018 06:39:03 +0000 (2 02:39 -0400)
committerJunio C Hamano <gitster@pobox.com>
Mon, 5 Nov 2018 04:14:35 +0000 (5 13:14 +0900)
treef41fbc4fa3d168221bca6522003e82fc157d1b92
parent0074c9110db6b8cddc9950f94f69d143379b25ed
diff: convert --check to use a hunk callback

The "diff --check" code needs to know the line number on which each hunk
starts in order to generate its output. We get that now by parsing the
hunk header line generated by xdiff, but it's much simpler to just pass
it directly using a hunk callback.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
diff.c