in reply to lvalue subs of a run-time persuasion

under 5.6.0, this works:
my $mysub = do { my $myvar; eval 'return sub : lvalue { $myvar }'; }; $mysub->() = 42; print $mysub->(), $/;
Outputs:
42
as i've heard many times before, the new features in 5.6.0 are a buggy area at times. this seems to be an inconsistency that should be checked, or submitted as a bug.

Replies are listed 'Best First'.
Re: Re: lvalue subs of a run-time persuasion
by MeowChow (Vicar) on Dec 06, 2000 at 09:10 UTC
    Thanks, this did the trick. "Experimental" indeed...