You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Applying the fix for f8ad5e2d63c6db61c5f88649ea30338eeaccae27 for the multibyte methods should resolve the AIOOBE issue. But apparently there is also another issue in the ANYCHAR_STAR operation when the end of input has been reached.
Output from Ruby 2.1.1 (or any other implementation based on Oniguruma):
IMO the last expression should also evaluate to 0 instead of nil.
ByteCodeMachine#opAnyCharStar() either needs to perform an early return and not update sprev when (s >= range) is true. Or it needs to push a stack entry for the current state when (s >= range) is true. Most likely the former, for example matching /A.*\>/ against "A" with the grep-syntax configuration triggers a different AIOOBE in ByteCodeMachine#opWordEnd().
To wrap things up, I'd say the underlying issue is in Oniguruma's ANYCHAR_STAR implementation, someone familiar with that code base should take a look.
anba
added a commit
to anba/es6draft
that referenced
this issue
Mar 4, 2014
To reproduce run
ruby -e '/foo.*\b/ =~ "foo"'
I was able to reproduce this error in JRuby 1.7.8, 1.7.10, and 1.7.11. It only occurs when the regex contains includes the pattern
.*\b
The text was updated successfully, but these errors were encountered: