]> CyberLeo.Net >> Repos - FreeBSD/releng/10.2.git/blob - contrib/netbsd-tests/lib/libc/regex/data/backref.in
- Copy stable/10@285827 to releng/10.2 in preparation for 10.2-RC1
[FreeBSD/releng/10.2.git] / contrib / netbsd-tests / lib / libc / regex / data / backref.in
1 # back references, ugh
2 a\(b\)\2c       bC      ESUBREG
3 a\(b\1\)c       bC      ESUBREG
4 a\(b*\)c\1d     b       abbcbbd abbcbbd bb
5 a\(b*\)c\1d     b       abbcbd
6 a\(b*\)c\1d     b       abbcbbbd
7 ^\(.\)\1        b       abc
8 a\([bc]\)\1d    b       abcdabbd        abbd    b
9 a\(\([bc]\)\2\)*d       b       abbccd  abbccd
10 a\(\([bc]\)\2\)*d       b       abbcbd
11 # actually, this next one probably ought to fail, but the spec is unclear
12 a\(\(b\)*\2\)*d         b       abbbd   abbbd
13 # here is a case that no NFA implementation does right
14 \(ab*\)[ab]*\1  b       ababaaa ababaaa a
15 # check out normal matching in the presence of back refs
16 \(a\)\1bcd      b       aabcd   aabcd
17 \(a\)\1bc*d     b       aabcd   aabcd
18 \(a\)\1bc*d     b       aabd    aabd
19 \(a\)\1bc*d     b       aabcccd aabcccd
20 \(a\)\1bc*[ce]d b       aabcccd aabcccd
21 ^\(a\)\1b\(c\)*cd$      b       aabcccd aabcccd