develooper Front page | perl.perl6.language | Postings from June 2005

Re: When can I take given as read?

Thread Previous
From:
Rod Adams
Date:
June 17, 2005 12:09
Subject:
Re: When can I take given as read?
Message ID:
42B31FF0.9000809@rodadams.net
Larry Wall wrote:

>Can anyone think of a good reason not to topicalize the first arg
>of ordinary subs these days?  Other than subtle encouragement toward
>use of multis?  I suppose it also makes refactoring between subs and
>methods more difficult in the case where you're adding an invocant,
>though it actually makes it easier in the case where you're just
>turning the first sub argument into an invocant because you realize
>you've been writing C-style OO code...
>  
>

I'm having a hard time coming up with good reasons why we don't

    s:g/<!before multi \s+> (sub|method) /{"single $1"}/;
    s:g/multi (sub|method) / $1 /;

And then have a "single" still be multi, just with a MMD distance of 
-Inf to everything.

-- Rod Adams



Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About