Re: RFC 118 (v1) lvalue subs: parameters, explicit assignment, and wantarray() changes

[email protected] (Damian Conway) Sun, 20 Aug 2000 16:32:16 +1000 (EST)
Newsgroups perl.perl6.language.subs
Message-ID <[email protected]>
   > I think we agree.
   > 
   > $foo is a tied variable
   > $bar is a normal variable
   > 
   > 	sub zap : lvalue { return $_[0] ? $foo : $bar }
   > 
   > 	zap(1) = 5;	# Goes to tied variable
   > 	zap(0) = 5;	# Normal store

And it would also be good to be able to overload operator = for objects,
so that assigment to then could be intercepted without having to tie the
reference as well.

Damian