From: Chris Morris Date: 2007-10-27T06:30:31+09:00 Subject: Re: Newlines included in bracket negation ------=_Part_4566_10980829.1193434231684 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Adding \n inside the brackets fixes it, I just wouldn't expect to have to do this since I didn't add the multiline mode option. require 'test/unit' class TestRE < Test::Unit::TestCase def test_newlines src = "happy\n\nbirthday" assert_equal("hday", src.scan(/h[^x\n]*?day/).to_s) end end -- Chris http://clabs.org ------=_Part_4566_10980829.1193434231684--