Skip Menu |

This queue is for tickets about the Moo CPAN distribution.

Report information
The Basics
Id: 91314
Status: resolved
Priority: 0/
Queue: Moo

People
Owner: Nobody in particular
Requestors: djerius [...] cpan.org
Cc:
AdminCc:

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



Subject: Obscure error message when init_arg => undef, required => 1
The following obviously nonsensical code (obvious being a relative term, it took me a while to notice that the attribute was both required and ignored during construction) package Foo; use Moo; has options => ( is => 'ro', init_arg => undef, required => 1, ); Foo->new; Results in the following somewhat obscure error message: Use of uninitialized value $required_init[0] in join or string at /home/dj/tmp/lib/perl5/Method/Generate/Constructor.pm line 180. Please consider making it less obscure. Thanks! Diab
A reasonable error is now emitted for this case. Will be in next release.
Resolved in 1.004000.