$ perl -wle 'sub 4 { print "yes" }' Illegal declaration of anonymous subroutine at -e line 1. $ # well, not like that. But it *is* possible: $ perl -lwe '*4 = sub { print "yes" }; 4->()' yes