Actions
Bug #13042
closedgsub segfaults when the pattern is a matching string and the replacement has an unmatched named capture
Bug #13042:
gsub segfaults when the pattern is a matching string and the replacement has an unmatched named capture
Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 2.3.3p222 (2016-11-21 revision 56859) [x86_64-darwin16]
Backport:
Description
Ruby segfaults for all code of the form
string.gsub(pattern, replacement)
where pattern is a substring of string (not a regex) and replacement includes a "named capture", such as \k<>. For example:
'hello'.gsub('hello', '\k<oops>')
Files
Actions