Josh Cheek wrote in post #990806:
> If you put a regex in a
> variable, it treats it as a boolean "is it an object?" and behaves as I
> stated previously. But if you put it in a literal, it plays Perl and
> checks
> to see if it matches against $_

Yes, this is a very ugly inheritance from Perl. Check out the flip-flop 
operator too :-)

-- 
Posted via http://www.ruby-forum.com/.