------- You are receiving this mail because: ------- You are on the CC list for the bug.
http://bugs.exim.org/show_bug.cgi?id=1447 Summary: Support for Enumerations Product: PCRE Version: N/A Platform: All OS/Version: All Status: NEW Severity: wishlist Priority: medium Component: Code AssignedTo: p...@hermes.cam.ac.uk ReportedBy: janmei...@gmail.com CC: pcre-dev@exim.org I believe regular expressions lack a construct (ignore the spaces): (?@ aaa | bbb(d*) | ccc(a*) | ddd) which, when applied to "cccaaaddd" results in this (PHP-alike notation): array("cccaaa", 2, "aaa") meaning the (?@ ... ) captures as an integer, and the clauses merely enumerate options. this may be an attractive substitute (with identical output): ( aaa (?0)| bbb(d*) (?1)| ccc(a*) (?2)| ddd (?3)) however, the numbers are now optional, which requires a dynamic typing scheme as in PHP. but it would also allow for: ( aaa (?"one")| bbb (?"two")| ccc (?"three")| ddd (?"four")) which means that certain patterns can be replaced by a canonical pattern. anyway, you can see where this is going. -- Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email -- ## List details at https://lists.exim.org/mailman/listinfo/pcre-dev