develooper Front page | perl.perl5.porters | Postings from January 2011

Re: Time to update POSIX.pm?

Thread Previous | Thread Next
From:
Eric Brine
Date:
January 29, 2011 18:46
Subject:
Re: Time to update POSIX.pm?
Message ID:
AANLkTinfuKtbq5S5qup7BFgb=YVT9o94=YVJvDoEN106@mail.gmail.com
On Sat, Jan 29, 2011 at 5:48 PM, Mark Overmeer <mark@overmeer.net> wrote:

> The unsplit POSIX.pm file is 1024 lines (21kb).  It does not use function
> signatures, but checks parameter list length manually...
>

There's no way to simply check parameter list length using "function
signatures", if by that you mean prototypes,

Attached is my compact rework of the POSIX module (434 lines, 15kb), as
>
example how small the module actually is. No regression tests run yet.
> All fancy tricks removed. But it may trigger some debate first ;-)
>

What about the fancy tricks you added? Prototypes change parsing rules, so
by definition, it is a backwards incompatible change. For example, your
changes causes

perl -e"use POSIX qw( ); @args=2; POSIX::exit(@args);"

to exit with code 1 instead of 2.

Thread Previous | Thread Next


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