develooper Front page | perl.perl5.porters | Postings from July 2014

Re: [perl #121638] 'Global symbol "$identifier" requires explicitpackage' error message

Thread Previous
From:
Eric Brine
Date:
July 30, 2014 02:16
Subject:
Re: [perl #121638] 'Global symbol "$identifier" requires explicitpackage' error message
Message ID:
CALJW-qFQUZF4P2uVWGj=rPT3uuUXMm-S+d=_DP2NMEM2m2GcDA@mail.gmail.com
On Tue, Jul 29, 2014 at 10:14 PM, Eric Brine <ikegami@adaelis.com> wrote:

> On Tue, Jul 29, 2014 at 1:26 PM, Karl Williamson via RT <
> perlbug-followup@perl.org> wrote:
>
>> > 2. Improve 'Variable "%s" is not imported' which you get when you use
>> > the wrong slot of an existing glob, such as in 'use strict; our $x =
>> > [3,1,4]; my $n = $x[0];' ?  The error has nothing to do with importing
>> > anything.  Even the perldiags entry is confusing, because it keeps
>> > talking about importing from a module.
>>
>> Could someone suggest better wording?
>>
>
> Easy! Global symbol "@x" requires explicit package name at -e line 1.
>

Well, that is to say, the same as the one received using 'use strict; my $n
= $x[0];'

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About