Hi, investigating further I have come to the conclusion that the attached ( and previously inlined ) patch is correct, in the sense that regular expressions of the failing type are now handled correctly.
e.g. A[\[:\]] should find an 'A' followed by one of '[',':',']' and it does now (old behavior: infinite loop). I don't seem to see any regression tests for reclass ? Also, and independent of this issue, certain regular expressions don't work as expected, e.g. A[\[:] unexpectedly matches nothing, but A[:\[] and A[\[\:] do... ( as far as I know ':' should match itself unless one of the special posix ranges is used. ) Review or comment would be greatly appreciated ! Thanks, - Karl
index c57632a..9e21bbe 100644 --- a/regexp/source/reclass.cxx +++ b/regexp/source/reclass.cxx @@ -1255,6 +1255,7 @@ Regexpr::regex_compile() break; } else { p = p1+1; + p1 ++; last_char = (sal_Unicode)':'; set_list_bit(last_char, b); }
_______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice