Slashdot Mirror


Perl 6: Apocalypse 6 Released

data64 writes "The latest Apocalypse talks about subroutines. Looks like we finally get type signatures which are way more powerful than the rudimentary prototypes available with Perl5."

1 of 247 comments (clear)

  1. Re:Perl is a Write-Only language by thoughtstream · · Score: 4, Informative
    That's exactly why we made it possible to modify Perl 6's grammar. As paradoxical as it sounds, adding that flexibility gives us a way of overcoming the downsides of Perl's TMTOWTDI philosophy.

    It will be comparatively simply for a coding team to create a "policy" module (say, Policy/Our/Preferred/Style.pm) that restricts coders to an agreed-upon subset of the language's syntax and features. Thereafter, so long as every module begins with use Policy::Our::Preferred::Style, the rest of the module simply won't compile unless it conforms to the team's coding standards.

    And I suspect that enough groups will want to do this that it will make sense for someone to write a front-end module that simplifies the creation of such policies. So all your team will need to write will be something like:
    module Policy::Our::Preferred::Style;

    use Policy::Specification
    blocks => 'K&R',
    elses => 'cuddled',
    disallow => << unless until statement_modifiers junctions>>,
    # etc.
    ;