Sha256: c7201cef79c71f961e38bc52b9275178d79576cbc096fc45c05eebb132fa6d5f
Contents?: true
Size: 597 Bytes
Versions: 18
Compression:
Stored size: 597 Bytes
Contents
package Moose::Exception::ReferencesAreNotAllowedAsDefault; our $VERSION = '2.2203'; use Moose; extends 'Moose::Exception'; with 'Moose::Exception::Role::ParamsHash'; has 'class' => ( is => 'ro', isa => 'Str', required => 1 ); has 'attribute_name' => ( is => 'ro', isa => 'Str', required => 1 ); sub _build_message { my $self = shift; "References are not allowed as default values, you must wrap the default of '". $self->attribute_name."' in a CODE reference (ex: sub { [] } and not [])"; } __PACKAGE__->meta->make_immutable; 1;
Version data entries
18 entries across 9 versions & 1 rubygems