CC: | reneeb via RT <perlbug-followup [...] perl.org>, Perl5 Porteros <perl5-porters [...] perl.org>, bug-Marpa-R2 [...] rt.cpan.org |
Subject: | Re: [perl #119047] Bleadperl v5.19.2-138-g137da2b breaks JKEGL/Marpa-R2-2.064000.tar.gz |
Date: | Mon, 29 Jul 2013 19:47:10 +0200 |
To: | demerphq <demerphq [...] gmail.com> |
From: | Leon Timmermans <fawaka [...] gmail.com> |
On Mon, Jul 29, 2013 at 7:26 PM, demerphq <demerphq@gmail.com> wrote:
Show quoted text
> Does this mean one cannot use
>
> sub foo () { 1 }
>
> to create a constant anymore?
>
> If so, IMO this breaks a lot of code.
If I understand this correctly, the problem is that this doesn't do
exactly what it used to do:
my $foo = 1;
for my $bar (@whatever) {
$foo++
*{$bar} = sub () { $foo }
}
Because $foo itself keeps changing value.
Leon