3 ms·
The Moose library is a pretty advanced OO library that was inspired by Common Lisp's CLOS & Smalltalk I think. Most Perl developers I know use a large amount of
by 7thaccount 6y ago
The Moose library is a pretty advanced OO library that was inspired by Common Lisp's CLOS & Smalltalk I think. Most Perl developers I know use a large amount of libraries as the language itself is lacking in many areas. A lot of people are fine with that, but I prefer kitchen-sink languages which are fairly opinionated.
- notyourday 6y agoI'm sorry, Moose is a pig. Its startup time is atrocious. Its run time overhead is non-trivial. People who use Moose in my experience just showboat that they can do OO. Does it help? Maybe. But what it surely does is it makes a program run and startup significantly slower.
- singingfish 6y agoThings have moved on. Moose is a bit of kitchen sink. These days you would generally choose Moo first unless you really needed the meta object features. Or to get incremental Moo(se) features you’d use Role::Tiny, Class::Method::Modifiers And Type::Tiny
- lizmat 6y agoAt least one of the inspirations of Moose, was the object system of Perl 6 at the time (now Raku https://raku.org https://raku.org using the #rakulang tag on social media). To create a Point class that has an x and a y attribute, you'd write: class Point { has $.x; has $.y; } Object instantiation is then done with: Point.new(x => 42, y => 666);
- 7thaccount 6y agoForgot about the inspiration from P6 (Raku). Thanks for mentioning Liz!