From: Joel Pearson Date: 2013-06-27T21:12:53+09:00 Subject: Re: Ruby 2.0 "invalid multibyte escape" in Regexp I think I've found a workaround, but it's not pretty, and I'm not sure whether the matching will work properly: @data[:VR] = line[1].strip.force_encoding("ASCII-8BIT").gsub( /#{ "\xB6|\xFF".force_encoding("ASCII-8BIT") }/, '' ) -- Posted via http://www.ruby-forum.com/.