Merge branch 'rs/xdiff-hunk-with-func-line'
commitd15c05a5d016bfd637fa1966951ae0686d17272e
authorJunio C Hamano <gitster@pobox.com>
Mon, 20 Jun 2016 18:01:04 +0000 (20 11:01 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 20 Jun 2016 18:01:04 +0000 (20 11:01 -0700)
tree684b70ac3e0abc8fe10b273f69440ddd5d74e581
parent6d8c5454b6f29568cd4ed231160f82c9579fe1f2
parent6f8d9bccb2c3694c62d14225976689c1e8c50fa5
Merge branch 'rs/xdiff-hunk-with-func-line'

"git show -W" (extend hunks to cover the entire function, delimited
by lines that match the "funcname" pattern) used to show the entire
file when a change added an entire function at the end of the file,
which has been fixed.

* rs/xdiff-hunk-with-func-line:
  xdiff: fix merging of appended hunk with -W
  grep: -W: don't extend context to trailing empty lines
  t7810: add test for grep -W and trailing empty context lines
  xdiff: don't trim common tail with -W
  xdiff: -W: don't include common trailing empty lines in context
  xdiff: ignore empty lines before added functions with -W
  xdiff: handle appended chunks better with -W
  xdiff: factor out match_func_rec()
  t4051: rewrite, add more tests
grep.c
t/t7810-grep.sh