Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: Global variable unexpectedly modified when passed by reference

by ikegami (Patriarch)
on Dec 10, 2014 at 07:13 UTC ( [id://1109857]=note: print w/replies, xml ) Need Help??


in reply to Re: Global variable unexpectedly modified when passed by reference
in thread Global variable unexpectedly modified when passed by reference

Perl really doesn’t have the notion of “[passing parameters by] reference.”

That's not true. In fact, Perl always passes parameters by reference.

$ perl -E'sub { $_[0] = "abc" }->($x); say $x' abc

I think you wanted to point out the phrase "passing by reference" has been incorrectly used instead of "passing a reference" throughout this thread, but you took a wrong turn somewhere.

  • Comment on Re^2: Global variable unexpectedly modified when passed by reference
  • Download Code

Log In?
Username:
Password:

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

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

    No recent polls found