From: Martin Stannard Date: 2003-08-22T23:46:16+09:00 Subject: irb regexp strangeness I've noticed the following behaviour when playing with irb: martin@beyond ruby $ cat t.rb puts 'testing' =~ /test/ puts 'testing' =~ 'test' puts 'testing' !~ /test/ puts 'testing' !~ 'test' martin@beyond ruby $ ruby t.rb 0 t.rb:2: warning: string =~ string will be obsolete; use explicit regexp 0 false t.rb:4: warning: string =~ string will be obsolete; use explicit regexp false Fine as a script, however: martin@beyond ruby $ irb irb(main):001:0> 'testing' =~ /test/ => 0 irb(main):002:0> 'testing' =~ 'test' (irb):2: warning: string =~ string will be obsolete; use explicit regexp => 0 irb(main):003:0> 'testing' !~ /test/ irb(main):004:0* ^C <-----IRB gets stuck here irb(main):004:0> 'testing' !~ 'test' (irb):4: warning: string =~ string will be obsolete; use explicit regexp => false irb(main):005:0> Why the hang on line 4? cheers, Martin