[ruby/yarp] fix: support newline-terminated regular expressions
Previously, parsing a snippet like this:
%r\nfoo\n
would result in tracking the second newline twice, resulting in a
failed runtime assertion.
Fixing that issue reveals another bug, which is that the first
newline was not being tracked at all. So we introduce a call to
yp_newline_list right when we construct the REGEXP_BEGIN token.
[ruby/yarp] fix: support newline-terminated regular expressions
Previously, parsing a snippet like this:
would result in tracking the second newline twice, resulting in a
failed runtime assertion.
Fixing that issue reveals another bug, which is that the first
newline was not being tracked at all. So we introduce a call to
yp_newline_list right when we construct the REGEXP_BEGIN token.
https://github.com/ruby/yarp/commit/0d5d759091