diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-10-16 11:20:06 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-10-16 11:20:06 +0000 |
commit | 78fea697769ce47a87c92f9baee8621f48f8ace3 (patch) | |
tree | 10b851c2269de5ffd8a7ebe364e6ae6c076faea8 /lib/delegate.rb | |
parent | 749b3aa7949b3717f33fee037e12c82bf4917026 (diff) |
* lib/delegate.rb (Delegator#method_missing): remove backtrace
lines _until_ `method_missing'.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25375 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/delegate.rb')
-rw-r--r-- | lib/delegate.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/delegate.rb b/lib/delegate.rb index d8a63660a4..da58048f36 100644 --- a/lib/delegate.rb +++ b/lib/delegate.rb @@ -137,7 +137,9 @@ class Delegator target.__send__(m, *args, &block) end rescue Exception - [email protected]_if{|s| %r"\A#{Regexp.quote(__FILE__)}:\d+:in `method_missing'\z"o =~ s} + if i = [email protected]{|s| %r"\A#{Regexp.quote(__FILE__)}:\d+:in `method_missing'\z"o =~ s} + $@[0..i] = [] + end ::Kernel::raise end end |