$ perl -wle' { package foo; sub handler { my $zahl; sub getinc {   $zahl++;   print "*** \$zahl(2): $zahl ***
"; } getinc(); } } foo::handler(); foo::handler(); foo::handler(); ' Variable "$zahl" will not stay shared at -e line 7. *** $zahl(2): 1 ***
*** $zahl(2): 2 ***
*** $zahl(2): 3 ***