Commit 9ce60fadda2a333756523299bff7772d05e69457

Jeff King 2014-04-08T18:40:05

userdiff: update ada patterns This is the moral equivalent of git/git@39a87a29ce364ed3337e535adce5973731ba2968 from Adrian Johnson <ajohnson@redneon.com>.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
diff --git a/src/userdiff.h b/src/userdiff.h
index bd69433..523f2f8 100644
--- a/src/userdiff.h
+++ b/src/userdiff.h
@@ -45,13 +45,13 @@ typedef struct {
 static git_diff_driver_definition builtin_defs[] = {
 
 IPATTERN("ada",
-	 "!^(.*[ \t])?(is new|renames|is separate)([ \t].*)?$\n"
+	 "!^(.*[ \t])?(is[ \t]+new|renames|is[ \t]+separate)([ \t].*)?$\n"
 	 "!^[ \t]*with[ \t].*$\n"
 	 "^[ \t]*((procedure|function)[ \t]+.*)$\n"
 	 "^[ \t]*((package|protected|task)[ \t]+.*)$",
 	 /* -- */
 	 "[a-zA-Z][a-zA-Z0-9_]*"
-	 "|[0-9][-+0-9#_.eE]"
+	 "|[-+]?[0-9][0-9#_.aAbBcCdDeEfF]*([eE][+-]?[0-9_]+)?"
 	 "|=>|\\.\\.|\\*\\*|:=|/=|>=|<=|<<|>>|<>"),
 
 IPATTERN("fortran",