[erlang-bugs] Re bug

PAILLEAU Eric <>
Sat Mar 3 13:39:11 CET 2012


Hi Robert,

your pattern can be shorten to a{0,n}a{n} and this way 23 is working.

4> re:run("aaa", "a?a?a?aaa").
{match,[{0,3}]}
5> re:run("aaa", "a{0,3}a{3}").
{match,[{0,3}]}
6> re:run(string:copies("a",23), "a{0,23}a{23}").
{match,[{0,23}]}
7> re:run(string:copies("a",24), "a{0,24}a{24}").
{match,[{0,24}]}

looks like this is a pattern string length limitation to more than 22*2
+ 22 = 66 and less than 23*2 + 23  = ... 69 ...

hum looks like it is not only pathological but sexual too :>) !!!!!

hope it can help...



More information about the erlang-bugs mailing list