Actually, that code won't work especially well either. (Try calling $maze->my_array.) This is because Moo lacks Moose's native attribute traits feature. (MooX::HandlesVia might help though.)
Also, FYI, Type::Tiny should run measurably faster than MooX::Types::MooseLike::Base, especially for a compound type constraint like ArrayRef[ArrayRef[Str]]. See my benchmarks.
In reply to Re^2: Passing arrayref to Moose attributes
by tobyink
in thread Passing arrayref to Moo attributes
by darcrossito
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |