The cause
LJ::S2::can_use_layer: looks innocuous enough
it certainly doesn't modify $_ directly...
but it does call some utility functions
One of them uses code like this to _sometimes_ read policy information from a file:
open (P, $file) or next; while (<P>) { s/\#.*//; next unless /\S/; # [...]
Which modifies $_...