summaryrefslogtreecommitdiff
path: root/lib/rdoc/generator
diff options
context:
space:
mode:
authorKevin Newton <[email protected]>2024-08-23 15:03:39 -0400
committergit <[email protected]>2024-08-23 19:18:14 +0000
commit3eb42054d9f50a0a65d014bb9e55349938deb97b (patch)
tree079aa436fb01576442c5cd7cd48e35816b902f1c /lib/rdoc/generator
parent3f6be01bfc34e13d9fd1f3fa4c4023735d631428 (diff)
[ruby/prism] Pass Unicode escapes on to onigmo
When we encounter an invalid unicode escape within a regular expression, we now pass that error on to Onigmo as if it didn't exist in the parser (which matches the upstream parser's behavior). We do this because there are tests that specify that you are allowed to have invalid Unicode escapes if they are within the context of a regular expression comment for a regular expression in extended mode. That looks like: /# \u /x Note that this _only_ applies to Unicode escapes (as opposed to applying to hex or meta/control escapes as well). Importantly it also only applies if the regular expression is terminated. An unterminated regular expression will still get error handling done in the parser. That would look like: /# \u that would result in the same error handling we have today. https://github.com/ruby/prism/commit/fb98034806
Diffstat (limited to 'lib/rdoc/generator')
0 files changed, 0 insertions, 0 deletions