develooper Front page | perl.perl6.language | Postings from April 2002

Re: named params, @_, and pass-by-reference

Thread Previous | Thread Next
From:
Jonathan Scott Duff
Date:
April 17, 2002 11:25
Subject:
Re: named params, @_, and pass-by-reference
Message ID:
20020417132501.F27359@cbi.tamucc.edu
On Wed, Apr 17, 2002 at 11:15:15AM -0700, Dave Storrs wrote:
> 	Perhaps using \ in the signature to indicate p-b-r is not the
> best...it could confuse people into thinking that they will need to
> manually dereference the variable, which they shouldn't need to do.
> 
> 	Is there a way to do this now?  If not, will there be a way in
> Perl6?

I think the syntax is now 

	sub load_date ($filename is rw; $version) { ... }

Changes to $filename within load_data() affect the caller.

-Scott
-- 
Jonathan Scott Duff
duff@cbi.tamucc.edu

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About