aboutsummaryrefslogtreecommitdiff
path: root/xdiff/xemit.c
diff options
context:
space:
mode:
authorPetr Baudis <pasky@suse.cz>2006-10-25 02:28:55 +0200
committerJunio C Hamano <junkio@cox.net>2006-10-25 12:57:33 -0700
commit70da769a4607dbbc4efc490287ead98175cf622b (patch)
tree0f34f0ab2d877df73ff2184678ae079fc1ecbc22 /xdiff/xemit.c
parent6e7d76baee08d0cd131d443c347c8a4bcd1004db (diff)
downloadgit-70da769a4607dbbc4efc490287ead98175cf622b.tar.gz
git-70da769a4607dbbc4efc490287ead98175cf622b.tar.xz
xdiff: Match GNU diff behaviour when deciding hunk comment worthiness of lines
This removes the '#' and '(' tests and adds a '$' test instead although I have no idea what it is actually good for - but hey, if that's what GNU diff does... Pasky only went and did as Junio sayeth. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'xdiff/xemit.c')
-rw-r--r--xdiff/xemit.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/xdiff/xemit.c b/xdiff/xemit.c
index 154c26fdc..07995ec33 100644
--- a/xdiff/xemit.c
+++ b/xdiff/xemit.c
@@ -86,8 +86,7 @@ static void xdl_find_func(xdfile_t *xf, long i, char *buf, long sz, long *ll) {
if (len > 0 &&
(isalpha((unsigned char)*rec) || /* identifier? */
*rec == '_' || /* also identifier? */
- *rec == '(' || /* lisp defun? */
- *rec == '#')) { /* #define? */
+ *rec == '$')) { /* mysterious GNU diff's invention */
if (len > sz)
len = sz;
while (0 < len && isspace((unsigned char)rec[len - 1]))