From: Robert Dober Date: 2008-08-01T06:20:36+09:00 Subject: Re: super with block On Thu, Jul 31, 2008 at 11:03 PM, Gregory Brown wrote: > It would be nice if MatchData was yielded by gsub instead of a string. > > -greg Well, maybe, but do not despair, while the $ special variables are not available in the block Regexp.last_match *is* 506/6 > cat gsub.rb && ruby gsub.rb 'abc'.gsub(/(.)(.)/){ p Regexp.last_match } # HTH Robert -- http://ruby-smalltalk.blogspot.com/ There's no one thing that's true. It's all true. -- Ernest Hemingway