Perl how to modify parameter -


How can the SQLite RTV function scaler modify the value of $ PDU directly? Normally the value of this syntax is a pass which is not close to the context, so far I have been assumed to be at least.

  My $ PDU; My $ addr = $ socket- & gt; Recv ($ PDU, MAXBYTES);  

I want to use this effect for my own purpose, so that one of the best tests will be the sub-rule which shows how it can be achieved.

Like:

  My $ PDU = "orig"; Sub-trial {my $ par1 = shift; $ Par1 = "test"; } Print "$ PDU \ n";  

As you know, "Origin" will not be "tested".

Thank you in advance.

Kind regards, Harman

While doing this, your function is well Should be documented,

  my $ PDU = "original"; Sub-trial {$ _ [0] = "test"; } Exam ($ PDU); Print "$ PDU \ n";  

or

  sub-trial {my ($ par1) = map \ $ _, @_; $$ paragraph 1 = "test"; }  

output

  test  

Comments