develooper Front page | perl.perl5.porters | Postings from February 2009

Re: deprecate UNIVERSAL->import

Thread Previous | Thread Next
From:
Rafael Garcia-Suarez
Date:
February 7, 2009 06:38
Subject:
Re: deprecate UNIVERSAL->import
Message ID:
b77c1dce0902070638u41ba9e1ak3c035ad7839b8580@mail.gmail.com
2009/1/26 Ricardo SIGNES <perl.p5p@rjbs.manxome.org>:
>
> I mean, honestly.
>
> There is no reason for UNIVERSAL.pm to be loaded, as it does two things: set a
> VERSION and setup an &import.  The import should not be used, as we've been
> asking people to stop for quite some time now, and it's just a lousy idea.  The
> VERSION isn't necessary because (a) there's no code to worry about changing and
> (b) the version is directly determinable from $] outside of blead, anyway.
>
> This patch introduces a lexical 'deprecated' warning'.

Thanks, applied as 1d9f57de1578571277e83372972a28d6d830e713, and I
also added a test in the next commit. Amazingly, the test suite
doesn't emit any warning.

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