This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Deprecate getopts.pl with a warning
authorSteffen Mueller <smueller@cpan.org>
Wed, 2 Sep 2009 18:02:47 +0000 (20:02 +0200)
committerSteffen Mueller <smueller@cpan.org>
Wed, 2 Sep 2009 18:02:47 +0000 (20:02 +0200)
lib/getopts.pl

index e30820a..ec1012a 100644 (file)
@@ -7,7 +7,11 @@
 # programming techniques.
 #
 # Suggested alternatives: Getopt::Long  or  Getopt::Std
-#
+
+warn( "The 'getopts.pl' legacy library is deprecated and will be"
+      . " removed in the next major release of perl. Please use the"
+      . " Getopt::Long or Getopt::Std module instead." );
+
 ;# Usage:
 ;#      do Getopts('a:bc');  # -a takes arg. -b & -c not. Sets opt_* as a
 ;#                           #  side effect.