in reply to Weird underscore/whitespace failing regex

I'm not sure, if I understand correctly, but please send us hex dump of the file (e.g. with hd -C file on Linux). Then it will be evident what mysterious bytes live under your text.

Replies are listed 'Best First'.
Re^2: Weird underscore/whitespace failing regex
by ikegami (Patriarch) on May 12, 2009 at 22:40 UTC

    Since we're dealing with a var,

    use Data::Dumper qw( Dumper ); $Data::Dumper::Useqq = 1; print(Dumper($str));
    or
    use Devel::Peek qw( Dump ); Dump($str);