in reply to slurping styles

In the second block, you never localize *FILE, which is a dubious practice anyway now that we can use this form:
open my $file, "<", $file or die "crap: $!"; my $raw = do { local $/; <$file> }; # sexy close $file;

Personally, my favorite slurping method these days is slurp() from File::Slurp. It's up to version 9_999.x, so you know it's good.

-Paul