From 15bd130215935ee74924c9240923ffbb25f70576 Mon Sep 17 00:00:00 2001 From: yugui Date: Sun, 25 Oct 2009 14:46:43 +0000 Subject: merges r24531 from trunk into ruby_1_9_1. -- * lib/delegate.rb (Delegator#method_missing): __FILE__ may contain multi-byte characters. a patch from Kenta Murata in [ruby-dev:39066]. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@25481 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/delegate.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/delegate.rb b/lib/delegate.rb index 025e901a8..cb16adbae 100644 --- a/lib/delegate.rb +++ b/lib/delegate.rb @@ -137,7 +137,7 @@ class Delegator target.__send__(m, *args, &block) end rescue Exception - $@.delete_if{|s| %r"\A#{__FILE__}:\d+:in `method_missing'\z"o =~ s} + $@.delete_if{|s| %r"\A#{Regexp.quote(__FILE__)}:\d+:in `method_missing'\z"o =~ s} ::Kernel::raise end end -- cgit