$cat test_moose.pl package NumberHolder; use Moose; has 'x' => (is => 'rw', isa => 'Int'); has 'y' => (is => 'rw', isa => 'Int'); __PACKAGE__->meta->make_immutable; package Main; my $z = NumberHolder->new(x => 1, y => 2); print "z's x and y = ", $z->x()," ", $z->y(), "\n"; $time perl test_moose.pl z's x and y = 1 2 real 0m1.48s user 0m1.06s sys 0m0.11s