B
Barun Singh
I'm seeing strange behavior with Ruby 1.8 when I try to evaluate a
regular expression inside an eval block.
Consider the following:
puts '1' =~ /^[\d]+$/
eval %Q{'1' =~ /^[\d]+$/}
Could someone explain why the eval statement returns an incorrect result
for the regexp match? Thanks...
regular expression inside an eval block.
Consider the following:
puts '1' =~ /^[\d]+$/
eval %Q{'1' =~ /^[\d]+$/}
Could someone explain why the eval statement returns an incorrect result
for the regexp match? Thanks...