OSSP CVS Repository

ossp - ossp-pkg/pcre/pcre_test.d/testinput2
Not logged in
[Honeypot]  [Browse]  [Directory]  [Home]  [Login
[Reports]  [Search]  [Ticket]  [Timeline
  [Raw

ossp-pkg/pcre/pcre_test.d/testinput2
/(a)b|/

/abc/
    abc
    defabc
    \Aabc
    *** Failers
    \Adefabc
    ABC

/^abc/
    abc
    \Aabc
    *** Failers
    defabc
    \Adefabc

/a+bc/

/a*bc/

/a{3}bc/

/(abc|a+z)/

/^abc$/
    abc
    *** Failers
    def\nabc

/ab\gdef/X

/(?X)ab\gdef/X

/x{5,4}/

/z{65536}/

/[abcd/

/[\B]/

/[z-a]/

/^*/

/(abc/

/(?# abc/

/(?z)abc/

/.*b/

/.*?b/

/cat|dog|elephant/
    this sentence eventually mentions a cat
    this sentences rambles on and on for a while and then reaches elephant

/cat|dog|elephant/S
    this sentence eventually mentions a cat
    this sentences rambles on and on for a while and then reaches elephant

/cat|dog|elephant/iS
    this sentence eventually mentions a CAT cat
    this sentences rambles on and on for a while to elephant ElePhant

/a|[bcd]/S

/(a|[^\dZ])/S

/(a|b)*[\s]/S

/(ab\2)/

/{4,5}abc/

/(a)(b)(c)\2/
    abcb
    \O0abcb
    \O3abcb
    \O6abcb
    \O9abcb
    \O12abcb 

/(a)bc|(a)(b)\2/
    abc
    \O0abc
    \O3abc
    \O6abc
    aba
    \O0aba
    \O3aba
    \O6aba
    \O9aba
    \O12aba

/abc$/E
    abc
    *** Failers
    abc\n
    abc\ndef

/(a)(b)(c)(d)(e)\6/

/the quick brown fox/
    the quick brown fox
    this is a line with the quick brown fox

/the quick brown fox/A
    the quick brown fox
    *** Failers
    this is a line with the quick brown fox

/ab(?z)cd/

/^abc|def/
    abcdef
    abcdef\B

/.*((abc)$|(def))/
    defabc
    \Zdefabc

/abc/P
    abc
    *** Failers
    
/^abc|def/P
    abcdef
    abcdef\B

/.*((abc)$|(def))/P
    defabc
    \Zdefabc
  
/the quick brown fox/P
    the quick brown fox
    *** Failers 
    The Quick Brown Fox 

/the quick brown fox/Pi
    the quick brown fox
    The Quick Brown Fox 

/abc.def/P
    *** Failers
    abc\ndef
    
/abc$/P
    abc
    abc\n 

/(abc)\2/P

/(abc\1)/P
    abc

/)/

/a[]b/

/[^aeiou ]{3,}/
    co-processors, and for 
    
/<.*>/
    abc<def>ghi<klm>nop

/<.*?>/
    abc<def>ghi<klm>nop

/<.*>/U
    abc<def>ghi<klm>nop
    
/<.*>(?U)/
    abc<def>ghi<klm>nop

/<.*?>/U
    abc<def>ghi<klm>nop
    
/={3,}/U
    abc========def
    
/(?U)={3,}?/
    abc========def
    
/(?<!bar|cattle)foo/
    foo
    catfoo 
    *** Failers
    the barfoo
    and cattlefoo   

/(?<=a+)b/

/(?<=aaa|b{0,3})b/

/(?<!(foo)a\1)bar/

/(?i)abc/

/(a|(?m)a)/

/(?i)^1234/

/(^b|(?i)^d)/

/(?s).*/

/[abcd]/S

/(?i)[abcd]/S

/(?m)[xy]|(b|c)/S

/(^a|^b)/m

/(?i)(^a|^b)/m

/(a)(?(1)a|b|c)/

/(?(?=a)a|b|c)/

/(?(1a)/

/(?(?i))/

/(?(abc))/

/(?(?<ab))/

/((?s)blah)\s+\1/

/((?i)blah)\s+\1/

/((?i)b)/DS

/(a*b|(?i:c*(?-i)d))/S

/a$/
    a
    a\n
    *** Failers 
    \Za
    \Za\n   

/a$/m
    a
    a\n
    \Za\n   
    *** Failers 
    \Za
    
/\Aabc/m

/^abc/m 

/^((a+)(?U)([ab]+)(?-U)([bc]+)(\w*))/
  aaaaabbbbbcccccdef

/(?<=foo)[ab]/S

/(?<!foo)(alpha|omega)/S

/(?!alphabet)[ab]/S

/(?<=foo\n)^bar/m

/(?>^abc)/m
    abc
    def\nabc
    *** Failers
    defabc   

/(?<=ab(c+)d)ef/

/(?<=ab(?<=c+)d)ef/

/(?<=ab(c|de)f)g/

/The next three are in testinput2 because they have variable length branches/

/(?<=bullock|donkey)-cart/
    the bullock-cart
    a donkey-cart race
    *** Failers
    cart
    horse-and-cart    
      
/(?<=ab(?i)x|y|z)/

/(?>.*)(?<=(abcd)|(xyz))/
    alphabetabcd
    endingxyz

/(?<=ab(?i)x(?-i)y|(?i)z|b)ZZ/
    abxyZZ
    abXyZZ
    ZZZ
    zZZ
    bZZ
    BZZ     
    *** Failers
    ZZ 
    abXYZZ 
    zzz
    bzz  

/(?<!(foo)a)bar/
    bar
    foobbar 
    *** Failers
    fooabar  

/This one is here because Perl 5.005_02 doesn't fail it/

/^(a)?(?(1)a|b)+$/
    *** Failers
    a 

/This one is here because I think Perl 5.005_02 gets the setting of $1 wrong/

/^(a\1?){4}$/
    aaaaaa
    
/These are syntax tests from Perl 5.005/

/a[b-a]/

/a[]b/

/a[/

/*a/

/(*)b/

/abc)/

/(abc/

/a**/

/)(/

/\1/

/\2/

/(a)|\2/

/a[b-a]/i

/a[]b/i

/a[/i

/*a/i

/(*)b/i

/abc)/i

/(abc/i

/a**/i

/)(/i

/:(?:/

/(?<%)b/

/a(?{)b/

/a(?{{})b/

/a(?{}})b/

/a(?{"{"})b/

/a(?{"{"}})b/

/(?(1?)a|b)/

/(?(1)a|b|c)/

/[a[:xyz:/

/(?<=x+)y/

/a{37,17}/

/abc/\

/abc/\P

/abc/\i

/(a)bc(d)/
    abcd
    abcd\C2
    abcd\C5
     
/(.{20})/
    abcdefghijklmnopqrstuvwxyz
    abcdefghijklmnopqrstuvwxyz\C1
    abcdefghijklmnopqrstuvwxyz\G1
     
/(.{15})/
    abcdefghijklmnopqrstuvwxyz
    abcdefghijklmnopqrstuvwxyz\C1\G1

/(.{16})/
    abcdefghijklmnopqrstuvwxyz
    abcdefghijklmnopqrstuvwxyz\C1\G1\L
    
/^(a|(bc))de(f)/
    adef\G1\G2\G3\G4\L 
    bcdef\G1\G2\G3\G4\L 
    adefghijk\C0 
    
/^abc\00def/
    abc\00def\L\C0 
    
/word ((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ 
)((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ )((?:[a-zA-Z0-9]+ 
)?)?)?)?)?)?)?)?)?otherword/M

/.*X/D

/.*X/Ds

/(.*X|^B)/D

/(.*X|^B)/Ds
    
/(?s)(.*X|^B)/D

/(?s:.*X|^B)/D

/\Biss\B/+
    Mississippi

/\Biss\B/+P
    Mississippi

/iss/G+
    Mississippi

/\Biss\B/G+
    Mississippi

/\Biss\B/g+
    Mississippi
    *** Failers
    Mississippi\A

/(?<=[Ms])iss/g+
    Mississippi

/(?<=[Ms])iss/G+
    Mississippi

/^iss/g+
    ississippi
    
/.*iss/g+
    abciss\nxyzisspqr 

/.i./+g
    Mississippi
    Mississippi\A
    Missouri river
    Missouri river\A  

/^.is/+g
    Mississippi

/^ab\n/g+
    ab\nab\ncd

/^ab\n/mg+
    ab\nab\ncd

/abc/

/abc|bac/

/(abc|bac)/

/(abc|(c|dc))/

/(abc|(d|de)c)/

/a*/

/a+/

/(baa|a+)/

/a{0,3}/

/baa{3,}/

/"([^\\"]+|\\.)*"/

/(abc|ab[cd])/

/(a|.)/

/a|ba|\w/

/abc(?=pqr)/

/...(?<=abc)/

/abc(?!pqr)/

/ab./

/ab[xyz]/

/abc*/

/ab.c*/

/a.c*/

/.c*/

/ac*/

/(a.c*|b.c*)/

/a.c*|aba/

/.+a/

/(?=abcda)a.*/

/(?=a)a.*/

/a(b)*/

/a\d*/

/ab\d*/

/a(\d)*/

/abcde{0,0}/

/ab\d+/

/a(?(1)b)/

/a(?(1)bag|big)/

/a(?(1)bag|big)*/

/a(?(1)bag|big)+/

/a(?(1)b..|b..)/

/ab\d{0}e/

/a?b?/
    a
    b
    ab
    \
    *** Failers
    \N     
    
/|-/
    abcd
    -abc
    \Nab-c
    *** Failers
    \Nabc     

/a*(b+)(z)(z)/P
    aaaabbbbzzzz
    aaaabbbbzzzz\O0
    aaaabbbbzzzz\O1
    aaaabbbbzzzz\O2
    aaaabbbbzzzz\O3
    aaaabbbbzzzz\O4
    aaaabbbbzzzz\O5
    
/^.?abcd/S 

/\(             # ( at start
  (?:           # Non-capturing bracket
  (?>[^()]+)    # Either a sequence of non-brackets (no backtracking)
  |             # Or
  (?R)          # Recurse - i.e. nested bracketed string
  )*            # Zero or more contents
  \)            # Closing )
  /x
    (abcd)
    (abcd)xyz
    xyz(abcd)
    (ab(xy)cd)pqr 
    (ab(xycd)pqr 
    () abc () 
    12(abcde(fsh)xyz(foo(bar))lmno)89
    *** Failers
    abcd 
    abcd)
    (abcd  

/\(  ( (?>[^()]+) | (?R) )* \) /xg
    (ab(xy)cd)pqr 
    1(abcd)(x(y)z)pqr

/\(  (?: (?>[^()]+) | (?R) ) \) /x
    (abcd)
    (ab(xy)cd)
    (a(b(c)d)e) 
    ((ab)) 
    *** Failers
    ()   

/\(  (?: (?>[^()]+) | (?R) )? \) /x
    ()
    12(abcde(fsh)xyz(foo(bar))lmno)89

/\(  ( (?>[^()]+) | (?R) )* \) /x
    (ab(xy)cd)

/\( ( ( (?>[^()]+) | (?R) )* ) \) /x
    (ab(xy)cd)

/\( (123)? ( ( (?>[^()]+) | (?R) )* ) \) /x
    (ab(xy)cd)
    (123ab(xy)cd)

/\( ( (123)? ( (?>[^()]+) | (?R) )* ) \) /x
    (ab(xy)cd)
    (123ab(xy)cd)

/\( (((((((((( ( (?>[^()]+) | (?R) )* )))))))))) \) /x
    (ab(xy)cd)

/\( ( ( (?>[^()<>]+) | ((?>[^()]+)) | (?R) )* ) \) /x
    (abcd(xyz<p>qrs)123)

/\( ( ( (?>[^()]+) | ((?R)) )* ) \) /x
    (ab(cd)ef)
    (ab(cd(ef)gh)ij)

/^[[:alnum:]]/D

/^[[:alpha:]]/D
             
/^[[:ascii:]]/D

/^[[:cntrl:]]/D

/^[[:digit:]]/D

/^[[:graph:]]/D

/^[[:lower:]]/D

/^[[:print:]]/D

/^[[:punct:]]/D

/^[[:space:]]/D

/^[[:upper:]]/D

/^[[:xdigit:]]/D

/^[[:word:]]/D

/^[[:^cntrl:]]/D

/^[12[:^digit:]]/D

/[01[:alpha:]%]/D

/[[.ch.]]/

/[[=ch=]]/

/[[:rhubarb:]]/

/[[:upper:]]/i
    A
    a 
    
/[[:lower:]]/i
    A
    a 

/((?-i)[[:lower:]])[[:lower:]]/i
    ab
    aB
    *** Failers
    Ab
    AB        

/[\200-\410]/

/^(?(0)f|b)oo/

/This one's here because of the large output vector needed/

/(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s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?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\d+(?:\s|$))(\w+)\s+(\270)/
    \O900 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 ABC ABC

/This one's here because Perl does this differently and PCRE can't at present/

/(main(O)?)+/
    mainmain
    mainOmain
    
/ End of testinput2 /

CVSTrac 2.0.1