[Issue 12366] New: Range violation in compile-time regex

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Mar 14 17:03:31 PDT 2014


https://d.puremagic.com/issues/show_bug.cgi?id=12366

           Summary: Range violation in compile-time regex
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: nobody at puremagic.com
        ReportedBy: thecybershadow at gmail.com
                CC: dmitry.olsh at gmail.com


--- Comment #0 from Vladimir Panteleev <thecybershadow at gmail.com> 2014-03-15 02:03:30 EET ---
import std.regex;

void main()
{
    auto re = ctRegex!(`^((?=(xx+?)\2+$)((?=\2+$)(?=(x+)(\4+$))\5){2})*x?$`);
    "xxxxxxxx".match(re);
}

This program crashes at runtime:
core.exception.RangeError at std.regex(3108): Range violation

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list