Re: RFC 132 (v1) subroutines should be able to return an lvalue

[email protected] (Jarkko Hietaniemi) Fri, 18 Aug 2000 11:11:12 -0500
Newsgroups perl.perl6.language.subs
Message-ID <[email protected]>
On Fri, Aug 18, 2000 at 10:47:54AM -0500, Jonathan Scott Duff wrote:
> On Fri, Aug 18, 2000 at 10:27:27AM -0500, Jarkko Hietaniemi wrote:
> > Error proneness?  (Is that a word?)
> 
> Looks like a word to me :-)

-neness just looked funny...

> >  	sub foo {
> >  	    my $lvalue;
> >  	    ...
> >  	    return $lvalue if want('LVALUE');
> >  	}
> 
> Hrm.  You're right.
> 
> 	sub foo {
> 	    return \$rvalue if want('LVALUE');
> 	}
> 
> (I'm just operating under the mode that "lreturn is icky, we can do
> better", but I don't know what "better" is)

attributes on keywords?  return:lvalue?  Argh, splutter, gasp, ...
doesn't work.

-- 
$jhi++; # http://www.iki.fi/jhi/
        # There is this special biologist word we use for 'stable'.
        # It is 'dead'. -- Jack Cohen