FAQ
Can you possibly provide a bit of code that, when run, reproduces this
warning? The 'package' key should normally exist with a defined value.

many thanks!
On Mon, Jan 18, 2016 at 10:25 AM, wrote:

Hi,

I see the following when calling $self->meta->add_attribute in my code
under perl 5.10.1:

Use of uninitialized value in string eq at
.../perl-5.10.1/lib/site_perl/5.10.1/x86_64-linux/Moose/Meta/Attribute.pm
line 1035.

I think the following code segment:

if (
$method
&& !$method->is_stub
&& !$method->isa('Class::MOP::Method::Accessor')
&& ( !$self->definition_context
$method->package_name eq $self->definition_context->{package} )
) {


should look like:


if (
$method
&& !$method->is_stub
&& !$method->isa('Class::MOP::Method::Accessor')
&& ( !$self->definition_context
exists(self->definition_context->{package}) && $method->package_name
eq $self->definition_context->{package} )
) {

--
Yuri

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 3 | next ›
Discussion Overview
groupmoose @
categoriesperl
postedJan 18, '16 at 6:26p
activeJan 19, '16 at 10:08p
posts3
users2
websiteiinteractive.com...

2 users in discussion

Shtil: 2 posts Karen Etheridge: 1 post

People

Translate

site design / logo © 2021 Grokbase