NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
Re: (Score:1)
Question: what's wrong with the following picture?
Answer: these sentences have nothing to do with each other [datanation.com]. Your argument is fallacious.
I did not condemn the idea of subroutine signatures at any point. I am deprecating source filters. I asked whether Sub::Signatures achieved the thing I want using the thing I don't, because I like Inline::Files [cpan.org] and Switch [cpan.org]
Re: (Score:2)
The sentences appear to have nothing to do with each other because there's a chain of logic between the two that's not explicitly spelled out. 1. Subroutine signatures eliminate common problems in Perl. 2. Source filters can be used to implement subroutine signatures. 3. Therefore, source filters can be used to make programming easier (yes, there are still a few gaps, but without being too pedantic, you can see where I'm coming from.) As for whether or not this addresses your particular concern, that
Re: (Score:1)
Re: (Score:2)
The only way I can think of is to rewrite the guts of Perl. Of course, that project is already started and it's called Perl 6 :) I think you might be able to do something with attributes, but that wouldn't give you the dispatching that is the primary benefit of this module.
Re: (Score:1)
Re: (Score:1)
Here's a suggestion that would reconcile both our views:
Make the main module filter-free, using some interface concoction like
multisub( foo => '($bar, $baz)', sub { } );(for demonstration purposes; I know this sucks), then put the filter in an add-on module that lets people writesub foo($bar, $baz) { }if that's what they want.Why have it your way or my way when both are possible?