From: Robin Barker Date: Thu, 26 Feb 2009 17:08:35 +0000 (+0000) Subject: add standard documentation to deprecate X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=04fd187ebcd6270e86c1279653a5d7873f04f5cb;p=p5sagit%2Fp5-mst-13.2.git add standard documentation to deprecate --- diff --git a/lib/deprecate.pm b/lib/deprecate.pm index e33d8c5..d016d77 100644 --- a/lib/deprecate.pm +++ b/lib/deprecate.pm @@ -51,3 +51,54 @@ EOM } 1; + +__END__ + +=head1 NAME + +deprecate - Perl (core) extension for deprecating the core version of a module, + in favour of the version on CPAN. + + +=head1 SYNOPSIS + + use deprecate; # always deprecate the module in which this occurs + + use if $[ > 5.010, 'deprecate'; # conditionally deprecate the module + + +=head1 DESCRIPTION + +This module is used using C (or something that calls +C<< deprecate->import() >>, for example C). + +If the module that includes C is located in a core library +directory, a deprecation warning is issued, encouraging the user to use +the version on CPAN. If that module is located in a site library, it is +the CPAN version, and no warning is issued. + +=head2 EXPORT + +None by default. The only method is C, called by C. + + +=head1 SEE ALSO + +First example to C was L. + + +=head1 AUTHOR + +Original version by Nicholas Clark + + +=head1 COPYRIGHT AND LICENSE + +Copyright (C) 2009 + +This library is free software; you can redistribute it and/or modify +it under the same terms as Perl itself, either Perl version 5.10.0 or, +at your option, any later version of Perl 5 you may have available. + + +=cut