[code]
irb(main):113:0> /l{2}x/ =~ 'llx'
=> 0
irb(main):109:0> /(lo){2}/ =~ 'lolo'
=> 0
irb(main):110:0> /(lo){2}x/ =~ 'lolox'
=> nil
irb(main):111:0> /(?:lo){2}x/ =~ 'lolox'
=> 0
[/code]

Note the third command returned nil but the fourth worked, any ideas?

[code]
$ ruby -v
ruby 1.9.1p376 (2009-12-07 revision 26041) [i686-linux]
[/code]
-- 
Posted via http://www.ruby-forum.com/.