perl -i.bak -pe"if(s/^(func|method)/#<<<\n$1/){ s/$/#>>>/ }" temp.pl