is there a reson or particular situation where it's better to use a bare word?Under the assumption that you're using 5.6+ I can't really think of any practical situations where a bareword filehandle is preferable to a lexical variable. Sure it's potentially less characters, by general practice visually distinctive in code and doesn't incur the overhead of a lexical variable (which, to be honest, is pretty much negligible in all but the most process intensive of operations) but I can't think of any practical situations where these factors outweigh the use of a lexical filehandle. I say practical situations because a bareword filehandle is great for obfuscation and golfing, but in code at large I'd say lexical filehandles would be prefered. If any monks can think of a situation where a bareword filehandle is indeed preferable to a lexical filehandle then please reply below.
_________
broquaint
In reply to Re: Re: Re: Passing filehandle to sub
by broquaint
in thread Passing filehandle to sub
by marctwo
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |