Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

replaced \e by \c[27]

Rakudo has regressed and no longer recognizes \e. [RT #75244]
commit e87e6a6bb6c08f6a799a66a4d0c1b16f9ba46406 1 parent 686e6ed
@masak authored
Showing with 5 additions and 3 deletions.
  1. +1 −1  lib/GGE/Perl6Regex.pm
  2. +2 −1  t/perl6regex/01-regex.t
  3. +2 −1  test-regex
View
2  lib/GGE/Perl6Regex.pm
@@ -26,7 +26,7 @@ class GGE::Perl6Regex {
my %esclist =
'h' => $h-whitespace,
'v' => $v-whitespace,
- 'e' => "\e",
+ 'e' => "\c[27]", # RAKUDO: No "\e". [RT #75244]
'f' => "\f",
'r' => "\r",
't' => "\t",
View
3  t/perl6regex/01-regex.t
@@ -88,7 +88,8 @@ sub backslash_escape($string) {
# RAKUDO: No .trans again yet
#return $string.trans(['\n', '\r', '\e', '\t', '\f'] =>
# ["\n", "\r", "\e", "\t", "\f"])\
- return replace_x $string.subst(/\\n/, "\n", :g).subst(/\\r/, "\r", :g).subst(/\\e/, "\e", :g).subst(/\\t/, "\t", :g).subst(/\\f/, "\f", :g);
+ # RAKUDO: No "\e". [RT #75244]
+ return replace_x $string.subst(/\\n/, "\n", :g).subst(/\\r/, "\r", :g).subst(/\\e/, "\c[27]", :g).subst(/\\t/, "\t", :g).subst(/\\f/, "\f", :g);
}
done_testing;
View
3  test-regex
@@ -26,5 +26,6 @@ sub backslash_escape($string) {
# RAKUDO: No .trans again yet
#return $string.trans(['\n', '\r', '\e', '\t', '\f'] =>
# ["\n", "\r", "\e", "\t", "\f"])\
- return replace_x $string.subst(/\\n/, "\n", :g).subst(/\\r/, "\r", :g).subst(/\\e/, "\e", :g).subst(/\\t/, "\t", :g).subst(/\\f/, "\f", :g);
+ # RAKUDO: No \e. [RT #75244]
+ return replace_x $string.subst(/\\n/, "\n", :g).subst(/\\r/, "\r", :g).subst(/\\e/, "\c[27]", :g).subst(/\\t/, "\t", :g).subst(/\\f/, "\f", :g);
}
Please sign in to comment.
Something went wrong with that request. Please try again.