Skip to content

Commit 1bb4abe

Browse files
committed
Merge branch 'tr/diff-words-test'
* tr/diff-words-test: t4034 (diff --word-diff): add a minimum Perl drier test vector t4034 (diff --word-diff): style suggestions userdiff: simplify word-diff safeguard t4034: bulk verify builtin word regex sanity
2 parents fc180d9 + 5269edf commit 1bb4abe

File tree

41 files changed

+933
-255
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+933
-255
lines changed

t/t4034-diff-words.sh

Lines changed: 207 additions & 231 deletions
Large diffs are not rendered by default.

t/t4034/bibtex/expect

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<BOLD>diff --git a/pre b/post<RESET>
2+
<BOLD>index 95cd55b..ddcba9b 100644<RESET>
3+
<BOLD>--- a/pre<RESET>
4+
<BOLD>+++ b/post<RESET>
5+
<CYAN>@@ -1,9 +1,10 @@<RESET>
6+
@article{aldous1987uie,<RESET>
7+
title={{Ultimate instability of exponential back-off protocol for acknowledgment-based transmission control of random access communication channels}},<RESET>
8+
author={Aldous, <RED>D.<RESET><GREEN>David<RESET>},
9+
journal={Information Theory, IEEE Transactions on},<RESET>
10+
volume={<RED>33<RESET><GREEN>Bogus.<RESET>},
11+
number={<RED>2<RESET><GREEN>4<RESET>},
12+
pages={219--223},<RESET>
13+
year=<GREEN>1987,<RESET>
14+
<GREEN> note={This is in fact a rather funny read since ethernet works well in practice. The<RESET> {<RED>1987<RESET><GREEN>\em pre} reference is the right one, however.<RESET>}<RED>,<RESET>
15+
}<RESET>

t/t4034/bibtex/post

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
@article{aldous1987uie,
2+
title={{Ultimate instability of exponential back-off protocol for acknowledgment-based transmission control of random access communication channels}},
3+
author={Aldous, David},
4+
journal={Information Theory, IEEE Transactions on},
5+
volume={Bogus.},
6+
number={4},
7+
pages={219--223},
8+
year=1987,
9+
note={This is in fact a rather funny read since ethernet works well in practice. The {\em pre} reference is the right one, however.}
10+
}

t/t4034/bibtex/pre

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
@article{aldous1987uie,
2+
title={{Ultimate instability of exponential back-off protocol for acknowledgment-based transmission control of random access communication channels}},
3+
author={Aldous, D.},
4+
journal={Information Theory, IEEE Transactions on},
5+
volume={33},
6+
number={2},
7+
pages={219--223},
8+
year={1987},
9+
}

t/t4034/cpp/expect

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
<BOLD>diff --git a/pre b/post<RESET>
2+
<BOLD>index 23d5c8a..7e8c026 100644<RESET>
3+
<BOLD>--- a/pre<RESET>
4+
<BOLD>+++ b/post<RESET>
5+
<CYAN>@@ -1,19 +1,19 @@<RESET>
6+
Foo() : x(0<RED>&&1<RESET><GREEN>&42<RESET>) { <GREEN>bar(x);<RESET> }
7+
cout<<"Hello World<RED>!<RESET><GREEN>?<RESET>\n"<<endl;
8+
<GREEN>(<RESET>1<GREEN>) (<RESET>-1e10<GREEN>) (<RESET>0xabcdef<GREEN>)<RESET> '<RED>x<RESET><GREEN>y<RESET>'
9+
[<RED>a<RESET><GREEN>x<RESET>] <RED>a<RESET><GREEN>x<RESET>-><RED>b a<RESET><GREEN>y x<RESET>.<RED>b<RESET><GREEN>y<RESET>
10+
!<RED>a<RESET><GREEN>x<RESET> ~<RED>a a<RESET><GREEN>x x<RESET>++ <RED>a<RESET><GREEN>x<RESET>-- <RED>a<RESET><GREEN>x<RESET>*<RED>b a<RESET><GREEN>y x<RESET>&<RED>b<RESET>
11+
<RED>a<RESET><GREEN>y<RESET>
12+
<GREEN>x<RESET>*<RED>b a<RESET><GREEN>y x<RESET>/<RED>b a<RESET><GREEN>y x<RESET>%<RED>b<RESET>
13+
<RED>a<RESET><GREEN>y<RESET>
14+
<GREEN>x<RESET>+<RED>b a<RESET><GREEN>y x<RESET>-<RED>b<RESET>
15+
<RED>a<RESET><GREEN>y<RESET>
16+
<GREEN>x<RESET><<<RED>b a<RESET><GREEN>y x<RESET>>><RED>b<RESET>
17+
<RED>a<RESET><GREEN>y<RESET>
18+
<GREEN>x<RESET><<RED>b a<RESET><GREEN>y x<RESET><=<RED>b a<RESET><GREEN>y x<RESET>><RED>b a<RESET><GREEN>y x<RESET>>=<RED>b<RESET>
19+
<RED>a<RESET><GREEN>y<RESET>
20+
<GREEN>x<RESET>==<RED>b a<RESET><GREEN>y x<RESET>!=<RED>b<RESET>
21+
<RED>a<RESET><GREEN>y<RESET>
22+
<GREEN>x<RESET>&<RED>b<RESET>
23+
<RED>a<RESET><GREEN>y<RESET>
24+
<GREEN>x<RESET>^<RED>b<RESET>
25+
<RED>a<RESET><GREEN>y<RESET>
26+
<GREEN>x<RESET>|<RED>b<RESET>
27+
<RED>a<RESET><GREEN>y<RESET>
28+
<GREEN>x<RESET>&&<RED>b<RESET>
29+
<RED>a<RESET><GREEN>y<RESET>
30+
<GREEN>x<RESET>||<RED>b<RESET>
31+
<RED>a<RESET><GREEN>y<RESET>
32+
<GREEN>x<RESET>?<RED>b<RESET><GREEN>y<RESET>:z
33+
<RED>a<RESET><GREEN>x<RESET>=<RED>b a<RESET><GREEN>y x<RESET>+=<RED>b a<RESET><GREEN>y x<RESET>-=<RED>b a<RESET><GREEN>y x<RESET>*=<RED>b a<RESET><GREEN>y x<RESET>/=<RED>b a<RESET><GREEN>y x<RESET>%=<RED>b a<RESET><GREEN>y x<RESET><<=<RED>b a<RESET><GREEN>y x<RESET>>>=<RED>b a<RESET><GREEN>y x<RESET>&=<RED>b a<RESET><GREEN>y x<RESET>^=<RED>b a<RESET><GREEN>y x<RESET>|=<RED>b<RESET>
34+
<RED>a<RESET><GREEN>y<RESET>
35+
<GREEN>x<RESET>,y
36+
<RED>a<RESET><GREEN>x<RESET>::<RED>b<RESET><GREEN>y<RESET>

t/t4034/cpp/post

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Foo() : x(0&42) { bar(x); }
2+
cout<<"Hello World?\n"<<endl;
3+
(1) (-1e10) (0xabcdef) 'y'
4+
[x] x->y x.y
5+
!x ~x x++ x-- x*y x&y
6+
x*y x/y x%y
7+
x+y x-y
8+
x<<y x>>y
9+
x<y x<=y x>y x>=y
10+
x==y x!=y
11+
x&y
12+
x^y
13+
x|y
14+
x&&y
15+
x||y
16+
x?y:z
17+
x=y x+=y x-=y x*=y x/=y x%=y x<<=y x>>=y x&=y x^=y x|=y
18+
x,y
19+
x::y

t/t4034/cpp/pre

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
Foo():x(0&&1){}
2+
cout<<"Hello World!\n"<<endl;
3+
1 -1e10 0xabcdef 'x'
4+
[a] a->b a.b
5+
!a ~a a++ a-- a*b a&b
6+
a*b a/b a%b
7+
a+b a-b
8+
a<<b a>>b
9+
a<b a<=b a>b a>=b
10+
a==b a!=b
11+
a&b
12+
a^b
13+
a|b
14+
a&&b
15+
a||b
16+
a?b:z
17+
a=b a+=b a-=b a*=b a/=b a%=b a<<=b a>>=b a&=b a^=b a|=b
18+
a,y
19+
a::b

t/t4034/csharp/expect

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
<BOLD>diff --git a/pre b/post<RESET>
2+
<BOLD>index 9106d63..dd5f421 100644<RESET>
3+
<BOLD>--- a/pre<RESET>
4+
<BOLD>+++ b/post<RESET>
5+
<CYAN>@@ -1,18 +1,18 @@<RESET>
6+
Foo() : x(0<RED>&&1<RESET><GREEN>&42<RESET>) { <GREEN>bar(x);<RESET> }
7+
cout<<"Hello World<RED>!<RESET><GREEN>?<RESET>\n"<<endl;
8+
<GREEN>(<RESET>1<GREEN>) (<RESET>-1e10<GREEN>) (<RESET>0xabcdef<GREEN>)<RESET> '<RED>x<RESET><GREEN>y<RESET>'
9+
[<RED>a<RESET><GREEN>x<RESET>] <RED>a<RESET><GREEN>x<RESET>-><RED>b a<RESET><GREEN>y x<RESET>.<RED>b<RESET><GREEN>y<RESET>
10+
!<RED>a<RESET><GREEN>x<RESET> ~<RED>a a<RESET><GREEN>x x<RESET>++ <RED>a<RESET><GREEN>x<RESET>-- <RED>a<RESET><GREEN>x<RESET>*<RED>b a<RESET><GREEN>y x<RESET>&<RED>b<RESET>
11+
<RED>a<RESET><GREEN>y<RESET>
12+
<GREEN>x<RESET>*<RED>b a<RESET><GREEN>y x<RESET>/<RED>b a<RESET><GREEN>y x<RESET>%<RED>b<RESET>
13+
<RED>a<RESET><GREEN>y<RESET>
14+
<GREEN>x<RESET>+<RED>b a<RESET><GREEN>y x<RESET>-<RED>b<RESET>
15+
<RED>a<RESET><GREEN>y<RESET>
16+
<GREEN>x<RESET><<<RED>b a<RESET><GREEN>y x<RESET>>><RED>b<RESET>
17+
<RED>a<RESET><GREEN>y<RESET>
18+
<GREEN>x<RESET><<RED>b a<RESET><GREEN>y x<RESET><=<RED>b a<RESET><GREEN>y x<RESET>><RED>b a<RESET><GREEN>y x<RESET>>=<RED>b<RESET>
19+
<RED>a<RESET><GREEN>y<RESET>
20+
<GREEN>x<RESET>==<RED>b a<RESET><GREEN>y x<RESET>!=<RED>b<RESET>
21+
<RED>a<RESET><GREEN>y<RESET>
22+
<GREEN>x<RESET>&<RED>b<RESET>
23+
<RED>a<RESET><GREEN>y<RESET>
24+
<GREEN>x<RESET>^<RED>b<RESET>
25+
<RED>a<RESET><GREEN>y<RESET>
26+
<GREEN>x<RESET>|<RED>b<RESET>
27+
<RED>a<RESET><GREEN>y<RESET>
28+
<GREEN>x<RESET>&&<RED>b<RESET>
29+
<RED>a<RESET><GREEN>y<RESET>
30+
<GREEN>x<RESET>||<RED>b<RESET>
31+
<RED>a<RESET><GREEN>y<RESET>
32+
<GREEN>x<RESET>?<RED>b<RESET><GREEN>y<RESET>:z
33+
<RED>a<RESET><GREEN>x<RESET>=<RED>b a<RESET><GREEN>y x<RESET>+=<RED>b a<RESET><GREEN>y x<RESET>-=<RED>b a<RESET><GREEN>y x<RESET>*=<RED>b a<RESET><GREEN>y x<RESET>/=<RED>b a<RESET><GREEN>y x<RESET>%=<RED>b a<RESET><GREEN>y x<RESET><<=<RED>b a<RESET><GREEN>y x<RESET>>>=<RED>b a<RESET><GREEN>y x<RESET>&=<RED>b a<RESET><GREEN>y x<RESET>^=<RED>b a<RESET><GREEN>y x<RESET>|=<RED>b<RESET>
34+
<RED>a<RESET><GREEN>y<RESET>
35+
<GREEN>x<RESET>,y

t/t4034/csharp/post

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
Foo() : x(0&42) { bar(x); }
2+
cout<<"Hello World?\n"<<endl;
3+
(1) (-1e10) (0xabcdef) 'y'
4+
[x] x->y x.y
5+
!x ~x x++ x-- x*y x&y
6+
x*y x/y x%y
7+
x+y x-y
8+
x<<y x>>y
9+
x<y x<=y x>y x>=y
10+
x==y x!=y
11+
x&y
12+
x^y
13+
x|y
14+
x&&y
15+
x||y
16+
x?y:z
17+
x=y x+=y x-=y x*=y x/=y x%=y x<<=y x>>=y x&=y x^=y x|=y
18+
x,y

t/t4034/csharp/pre

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
Foo():x(0&&1){}
2+
cout<<"Hello World!\n"<<endl;
3+
1 -1e10 0xabcdef 'x'
4+
[a] a->b a.b
5+
!a ~a a++ a-- a*b a&b
6+
a*b a/b a%b
7+
a+b a-b
8+
a<<b a>>b
9+
a<b a<=b a>b a>=b
10+
a==b a!=b
11+
a&b
12+
a^b
13+
a|b
14+
a&&b
15+
a||b
16+
a?b:z
17+
a=b a+=b a-=b a*=b a/=b a%=b a<<=b a>>=b a&=b a^=b a|=b
18+
a,y

0 commit comments

Comments
 (0)