diff options
author | Jeremy Evans <code@jeremyevans.net> | 2022-06-20 15:17:23 -0700 |
---|---|---|
committer | Jeremy Evans <code@jeremyevans.net> | 2022-06-20 15:56:28 -0700 |
commit | 596f4b0d3ab8bc2559a52396d3a29ce62e6a3694 (patch) | |
tree | afa9d3483b3f11e3504beed03221db48962dfa19 /re.c | |
parent | 850b54612c21ee46ba8c03bf028e8426b9b4786c (diff) |
Document that Regexp#source does not retain lexer escapes
Related to [Feature #18838]
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/6047
Diffstat (limited to 're.c')
-rw-r--r-- | re.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -487,10 +487,14 @@ rb_reg_desc(const char *s, long len, VALUE re) * * /ab+c/ix.source # => "ab+c" * - * Note that escape sequences are retained as is: + * Regexp escape sequences are retained: * * /\x20\+/.source # => "\\x20\\+" * + * Lexer escape characters are not retained: + * + * /\//.source # => "/" + * */ static VALUE |