Evan Carroll wrote:
While I see the point. The stack trace is equally useless here.
at main::(-e:1)
ecarr...@x60s:~$ perl -MDevel::SimpleTrace -E'package Foo; use Moose;
has "bar" => (is => "ro", required => 0, isa => "Int", builder =>
"buildit", lazy => 1); sub buildit { return } package main; my $foo =
Foo->new(); say $foo->bar()'
Attribute (bar) does not pass the type constraint because: Validation
failed for 'Int' failed with value undef at -e line 1
at Moose::Meta::Class::raise_error(unknown source)
at
Moose::Meta::Class::throw_error(/usr/local/share/perl/5.10.0/Moose/Meta/Class.pm:582)
at Foo::bar(accessor bar defined at -e:8)
at main::(-e:1)
I mean, that error is pretty damn good, so I'm assuming the argument
is about simply not stating explicitly the error happened in the
slot's initiation rather than an explicit runtime setting.
Yeah. I had to get to the actual error throwing mechanism in order to figure
out where the problem was coming from.