From 71c534c962152295778655ea6bfb86331b970776 Mon Sep 17 00:00:00 2001 From: duerst Date: Wed, 22 Oct 2014 10:18:20 +0000 Subject: tool/unicode_norm_gen.rb: Fixed escaping of backslash and double quote ('\\\&' -> "\\\\\\\&"; double quoted string is needed to make \& mean last match; double double backslashes are needed because of two layers of escaping). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48089 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- tool/unicode_norm_gen.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tool') diff --git a/tool/unicode_norm_gen.rb b/tool/unicode_norm_gen.rb index 5f2545075b..766be26dc4 100644 --- a/tool/unicode_norm_gen.rb +++ b/tool/unicode_norm_gen.rb @@ -17,7 +17,7 @@ class Integer elsif self>0x7f "\\u#{to_s(16).upcase.rjust(4, '0')}" else - chr.sub(/[\\\"]/, '\\\&') + chr.sub(/[\\\"]/, "\\\\\\\&") end end end -- cgit v1.2.3