Skip Menu |

This queue is for tickets about the Marpa-R2 CPAN distribution.

Report information
The Basics
Id: 87429
Status: resolved
Priority: 0/
Queue: Marpa-R2

People
Owner: Nobody in particular
Requestors: demerphq [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



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: Tue, 30 Jul 2013 10:53:04 +0200
To: Leon Timmermans <fawaka [...] gmail.com>
From: demerphq <demerphq [...] gmail.com>
On 29 July 2013 19:47, Leon Timmermans <fawaka@gmail.com> wrote: Show quoted text
> On Mon, Jul 29, 2013 at 7:26 PM, demerphq <demerphq@gmail.com> wrote:
>> 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.
Ah yes, it should be: *$bar= eval "sub () { $foo }"; So that the $foo is frozen. Yves -- perl -Mre=debug -e "/just|another|perl|hacker/"
Closed as duplicate of ticket 87384