|
|
|
|
|
by wantarray
4152 days ago
|
|
> Why would I learn this rather than Haskell? You wouldn't. That is to say: You might learn Haskell if you want do write 100% functional code, and Perl 6 if you want to write imperative/procedural/OO code with functional idioms mixed in here and there (in places where that facilitates a more elegant approach). I.e. the two languages are not really competing in the same category. Even though Perl 6 has first-class code objects, closure semantics, basic pattern-matching, lazy lists, immutable data types, and so on, a lot of the syntax and default behaviors are geared towards stateful programming styles, which - combined with the lack of static typing - means that strictly sticking to functional programming in Perl 6 will be awkward and you'd be better off using a dedicated functional language if that's what you want. |
|
A key feature of Perl 6 is optional static nominal typing:
http://www.reddit.com/r/perl6/wiki/gradualtyping