6 use Benchmark qw[cmpthese];
10 This benchmark compares the overhead of a
11 auto-created type constraint vs. none at
12 all vs. a custom-created type.
19 use Moose::Util::TypeConstraints;
21 has 'baz' => (is => 'rw');
22 has 'bar' => (is => 'rw', isa => 'Foo');
23 #has 'boo' => (is => 'rw', isa => type 'CustomFoo' => where { blessed($_) && $_->isa('Foo') });
30 'w/out_constraint' => sub {
33 'w_constraint' => sub {
36 #'w_custom_constraint' => sub {