regcomp.c: Optimization not valid for Latin Sharp S
The regex optimizer optimizes some quantifier expressions into simpler
versions. It turns out that these optimizations don't work on a
quantified, folded LATIN SMALL LETTER SHARP S under /d. This is due to
the size differential of the fold from the source.
This commit omits the optimization if this circumstance occurs anywhere
in the regex prior to the determination of whether to optimize or not.
I tried adding a parameter to study_chunk() to indicate more locally if
the optimization should be excluded or not; but my first attempt did not
fix the bug, and I chose to not pursue that line. This character is so
abnormal that it's probably best anyway to be overly cautious when
confronted with it.