When are slurpy parameters useful? |
|||
|
|
|
|
|
Slurpy list parameters
provide list deconstruction. This alone is useful. In
conjunction with multi subs, you now have the
makings of a functional language ---
But without strong typing, a wealth of operators, referential tranparency, combinators.
You may encounter these in a module you download, but I cannot imagine the average (or even above average or best) Perl shop switching to this mode of programming. It is wordier than the imperative equivalent as well as the functional equivalent in a different language.
|
Slurpy Sub Parms, Multi Subs and Perl 6 Functional Programming
Terrence Brannon (2005-03-08) |
|