mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
11ae581a4a
Ruby uses a recursive algorithm for handling control/meta escapes in strings (read_escape). However, the equivalent code for regexps (tokadd_escape) in did not use a recursive algorithm. Due to this, Handling of control/meta escapes in regexp did not have the same behavior as in strings, leading to behavior such as the following returning nil: ```ruby /\c\xFF/ =~ "\c\xFF" ``` Switch the code for handling \c, \C and \M in literal regexps to use the same code as for strings (read_escape), to keep behavior consistent between the two. Fixes [Bug #14367] |
||
---|---|---|
.. | ||
anchors_spec.rb | ||
back-references_spec.rb | ||
character_classes_spec.rb | ||
empty_checks_spec.rb | ||
encoding_spec.rb | ||
escapes_spec.rb | ||
grouping_spec.rb | ||
interpolation_spec.rb | ||
modifiers_spec.rb | ||
repetition_spec.rb | ||
subexpression_call_spec.rb |