> The only exception for non-core-like functions that I find > sensible is using the empty prototype for constant functions: > $ perl -wE 'sub FOO {3}; say FOO+1' > 3 > $ perl -wE 'sub FOO () {3}; say FOO+1' > 4 > Without the prototype the "FOO+1" is parsed as "FOO(+1)" > instead of "FOO()+1". Even that is only if you just happen to have a forward declaration of the function. Otherwise it's a filehandle literal in the dative slot: % perl -wE 'say FOO+1; sub FOO {3}' say() on unopened filehandle FOO at -e line 1. % perl -wE 'say FOO(+1); sub FOO {3}' 3 % perl -wE 'say FOO()+1; sub FOO {3}' 4 --tomThread Previous | Thread Next