regcomp.c: Clean up ANYOF_CLASS handling.
authorKarl Williamson <public@khwilliamson.com>
Thu, 27 Dec 2012 19:34:41 +0000 (12:34 -0700)
committerKarl Williamson <public@khwilliamson.com>
Fri, 28 Dec 2012 17:38:55 +0000 (10:38 -0700)
commitb25a103638bc5111446c1e65a21db00a6e13acc1
tree496e9f487f356e04e3199d2f8d1938aa5f588dfc
parentf0c12ea8fdc0aca86872e322ec9009f1e933f9ed
regcomp.c: Clean up ANYOF_CLASS handling.

The ANYOF_CLASS flag is used in ANYOF nodes (for [bracketed] and the
synthetic start class) only when matching something like \w, [:punct:]
etc., under /l (locale).  It should not be set unless /l is specified.
However, it was always getting set for the synthetic start class.  This
commit fixes that.  The previous code was masking errors in which it was
being tested for unnecessarily, and for much of the 5.17 series, the
synthetic start class was always set to test for locale, which was a
waste of cpu when no locale was specified.
regcomp.c
regcomp.h
t/re/re_tests