Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^2: why avoid & on function call

by chromatic (Archbishop)
on Dec 27, 2020 at 17:34 UTC ( [id://11125798]=note: print w/replies, xml ) Need Help??


in reply to Re: why avoid & on function call
in thread why avoid & on function call

others place them at the start because of the behaviour when not using the ampersand

Another reason is to avoid accidentally closing over lexical variables declared outside of function scope.


Improve your skills with Modern Perl: the free book.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11125798]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2024-06-24 19:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.