diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2014-04-04 13:12:58 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2014-04-04 13:12:58 +0900 |
| commit | 5f2817b36c32ff71031c514b2fdf51ba6b74d83c (patch) | |
| tree | aca47a62cf81bb705720d4897ae4e8df30f5bb8c /src/parse.y | |
| parent | 59cd24d41f1e6b5e25d35103c0720e8aa8cae0b6 (diff) | |
| download | mruby-5f2817b36c32ff71031c514b2fdf51ba6b74d83c.tar.gz mruby-5f2817b36c32ff71031c514b2fdf51ba6b74d83c.zip | |
backslash escapes in regexp should be addressed by Regexp processor; close #2005
Diffstat (limited to 'src/parse.y')
| -rw-r--r-- | src/parse.y | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/parse.y b/src/parse.y index 2cf1571d3..ec27a2c51 100644 --- a/src/parse.y +++ b/src/parse.y @@ -3829,6 +3829,10 @@ parse_string(parser_state *p) tokadd(p, '\n'); } } + else if (type & STR_FUNC_REGEXP) { + tokadd(p, '\\'); + tokadd(p, c); + } else { pushback(p, c); tokadd(p, read_escape(p)); |
