There's more than one way to do things | |
PerlMonks |
Re^2: Mouse as prelude to Moose?by jasonk (Parson) |
on Feb 05, 2009 at 21:11 UTC ( [id://741694]=note: print w/replies, xml ) | Need Help?? |
By default Moose (and I'd assume also Mouse) will allow you to pass any keys you want to an object constructor. So what happens is just that the ks is being ignored. The reason it doesn't throw an error for an unknown key is so you can do something like this:
You can turn this behavior off for your own modules with MooseX::StrictConstructor.
In Section
Seekers of Perl Wisdom
|
|