avoid v-strings with require/use
authorRonald J. Kimball <rjk@linguist.dartmouth.edu>
Fri, 21 Sep 2001 12:34:40 +0000 (08:34 -0400)
committerAbhijit Menon-Sen <ams@wiw.org>
Fri, 21 Sep 2001 17:08:24 +0000 (17:08 +0000)
Message-Id: <20010921123440.A148500@linguist.thayer.dartmouth.edu>

p4raw-id: //depot/perl@12113

51 files changed:
ext/ByteLoader/bytecode.h
ext/Data/Dumper/Dumper.pm
ext/Devel/DProf/DProf.pm
ext/IO/lib/IO/Dir.pm
ext/IO/lib/IO/File.pm
ext/IO/lib/IO/Handle.pm
ext/IO/lib/IO/Pipe.pm
ext/IO/lib/IO/Seekable.pm
ext/Opcode/Opcode.pm
lib/AnyDBM_File.pm
lib/AutoLoader.pm
lib/AutoSplit.pm
lib/Class/Struct.pm
lib/Cwd.pm
lib/Dumpvalue.pm
lib/ExtUtils/Command.pm
lib/ExtUtils/Install.pm
lib/ExtUtils/Installed.pm
lib/ExtUtils/Liblist.pm
lib/ExtUtils/Mksymlists.pm
lib/ExtUtils/Packlist.pm
lib/Fatal.pm
lib/File/Basename.pm
lib/File/CheckTree.pm
lib/File/Compare.pm
lib/File/Copy.pm
lib/File/Find.pm
lib/File/Path.pm
lib/File/stat.pm
lib/FileHandle.pm
lib/Math/Trig.pm
lib/Net/Ping.pm
lib/Net/hostent.pm
lib/Net/netent.pm
lib/Net/protoent.pm
lib/Net/servent.pm
lib/Shell.pm
lib/Tie/Array.pm
lib/Tie/Handle.pm
lib/Time/Local.pm
lib/Time/gmtime.pm
lib/Time/localtime.pm
lib/User/grent.pm
lib/base.pm
lib/diagnostics.pm
lib/fields.pm
lib/vars.pm
pod/perl56delta.pod
pod/perlfunc.pod
pp_ctl.c
utils/pl2pm.PL

index e7ac6c8efd0129d892543da16d7b5e384b21cc06..73f354429484b3995b207b2b45aa782a3354c491 100644 (file)
@@ -205,7 +205,7 @@ typedef IV IV64;
        bset_obj_store(aTHX_ bstate, obj, (I32)ix) : (bstate->bs_obj_list[ix] = obj)
 
 /* NOTE: the bytecode header only sanity-checks the bytecode. If a script cares about
- * what version of Perl it's being called under, it should do a 'require 5.6.0' or
+ * what version of Perl it's being called under, it should do a 'use 5.006_001' or
  * equivalent. However, since the header includes checks requiring an exact match in
  * ByteLoader versions (we can't guarantee forward compatibility), you don't 
  * need to specify one:
index 5897e1ffe7689eafbe4dce8bc802c58599199b6f..6cf7d35e4d2eba0f193531c0123666c2a481b275 100644 (file)
@@ -13,7 +13,7 @@ $VERSION = '2.103';
 
 #$| = 1;
 
-require 5.6.1;
+use 5.006_001;
 require Exporter;
 use XSLoader ();
 require overload;
index 6eb4c224f4758fd22ee701c5f9fdb85e8e0d2895..d5d8a82a519091d0f42e55e49cdb1166dc9b4b7b 100644 (file)
@@ -1,4 +1,4 @@
-require 5.6.1;
+use 5.006_001;
 
 =head1 NAME
 
index d09eb7ff0b6c01e113c2847cc5f0aaa75d2e8969..0a083ef9aa8a7d1ac4cd40d0c703c8253146ab84 100644 (file)
@@ -6,7 +6,7 @@
 
 package IO::Dir;
 
-use 5.6.0;
+use 5.006;
 
 use strict;
 use Carp;
index 83699fb55b4cc3c595f9d9d6eaac287ac62dc04b..240033f3045db0f1a25fdfb5bf2270648256c14e 100644 (file)
@@ -103,7 +103,7 @@ Derived from FileHandle.pm by Graham Barr E<lt>F<gbarr@pobox.com>E<gt>.
 
 =cut
 
-require 5.6.1;
+use 5.006_001;
 use strict;
 our($VERSION, @EXPORT, @EXPORT_OK, @ISA);
 use Carp;
index 37aa99c7bfeb62ebf0fe6790ce4f9fcb22dc4fd0..6fdba173049c2c24b7c3f3ee85a0d08be96f3cfc 100644 (file)
@@ -247,7 +247,7 @@ Derived from FileHandle.pm by Graham Barr E<lt>F<gbarr@pobox.com>E<gt>
 
 =cut
 
-require 5.6.1;
+use 5.006_001;
 use strict;
 our($VERSION, @EXPORT_OK, @ISA);
 use Carp;
index 27747ce43c91ece9dc987466b54bbae38d5993a7..a500f292805dbb062cc6febd10bcf36a8bc5c18b 100644 (file)
@@ -6,7 +6,7 @@
 
 package IO::Pipe;
 
-require 5.6.1;
+use 5.006_001;
 
 use IO::Handle;
 use strict;
index 987cbc39d5ac94a1be227595b160dd26dd76eeff..684b8bc70db0a097e3f8c64bc230b65e403d3acf 100644 (file)
@@ -94,7 +94,7 @@ Derived from FileHandle.pm by Graham Barr E<lt>gbarr@pobox.comE<gt>
 
 =cut
 
-require 5.6.1;
+use 5.006_001;
 use Carp;
 use strict;
 our($VERSION, @EXPORT, @ISA);
index 544b2845b78bcccdebd1bfc829f69b3a72a02ebe..1524f6762a01b0b6e6d40112b2c8b57dd3965fe5 100644 (file)
@@ -1,6 +1,6 @@
 package Opcode;
 
-require 5.6.1;
+use 5.006_001;
 
 use strict;
 
index 476df473a5464a2d85361d6e53b3762bd75a1985..d73abab0f9e1c87e0359c907b8fea93d71514aed 100644 (file)
@@ -1,6 +1,6 @@
 package AnyDBM_File;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '1.00';
 our @ISA = qw(NDBM_File DB_File GDBM_File SDBM_File ODBM_File) unless @ISA;
 
index 4e1eb1b064af805a7b6c4d1f0f311796d74c9d11..b42d5ff4b68cde79580f8a0eadaf8c8bb981a58a 100644 (file)
@@ -1,6 +1,6 @@
 package AutoLoader;
 
-use 5.6.0;
+use 5.006_001;
 our(@EXPORT, @EXPORT_OK, $VERSION);
 
 my $is_dosish;
index 281d5c6ce2757db000d0f2edf7e06205c1b93aaf..ae119d3d1bec279538209b831ed1945c1ef99a6e 100644 (file)
@@ -1,6 +1,6 @@
 package AutoSplit;
 
-use 5.6.1;
+use 5.006_001;
 use Exporter ();
 use Config qw(%Config);
 use Carp qw(carp);
index ee231905cfcd04dac06ce01d3c265794275fe602..bad4f78165f6141cd52017f94532eb6ba2c4e473 100644 (file)
@@ -2,7 +2,7 @@ package Class::Struct;
 
 ## See POD after __END__
 
-use 5.6.1;
+use 5.006_001;
 
 use strict;
 use warnings::register;
index 8b9a780be0d32531580c065430291c8d33c7e1df..01f5ce43eab6e7a98b8218db0bc578f30df7a164 100644 (file)
@@ -1,5 +1,5 @@
 package Cwd;
-require 5.6.0;
+use 5.006;
 
 =head1 NAME
 
index 456261a9998d5ee573433e30d9685f7dc1cbbea0..427f57cc4257072469ff26398df65f745103815b 100644 (file)
@@ -1,4 +1,4 @@
-use 5.6.1;                     # for (defined ref) and $#$v and our
+use 5.006_001;                 # for (defined ref) and $#$v and our
 package Dumpvalue;
 use strict;
 our $VERSION = '1.00';
index b7b41cd7cea5dd84ac92aec12f267a161298b28a..bf1e0e5df88c40004b45e8183a1dd7cd0f0e76cc 100644 (file)
@@ -1,6 +1,6 @@
 package ExtUtils::Command;
 
-use 5.6.1;
+use 5.006_001;
 use strict;
 # use AutoLoader;
 use Carp;
index d70104202acf692f32acd4d05d5ddfade30057a2..14a6e08558b2d70663b08a963a27ab23758d6286 100644 (file)
@@ -1,6 +1,6 @@
 package ExtUtils::Install;
 
-use 5.6.1;
+use 5.006_001;
 our(@ISA, @EXPORT, $VERSION);
 $VERSION = substr q$Revision: 1.29 $, 10;
 # $Date: 1998/01/25 07:08:24 $
index 942185ed878992930330daf1d7cb7ce0b497c1e1..7433c01dc8369d2db4f2772bce3fd1c71736d177 100644 (file)
@@ -1,6 +1,6 @@
 package ExtUtils::Installed;
 
-use 5.6.1;
+use 5.006_001;
 use strict;
 use Carp qw();
 use ExtUtils::Packlist;
index ae565fce022822dd7ecf0d6d8556470c95234ab0..09421e331fd6b2d6cc70acca3b26ae867fd85f75 100644 (file)
@@ -21,7 +21,7 @@ package ExtUtils::Liblist::Kid;
 # This kid package is to be used by MakeMaker.  It will not work if
 # $self is not a Makemaker.
 
-use 5.6.1;
+use 5.006_001;
 # Broken out of MakeMaker from version 4.11
 
 our $VERSION = substr q$Revision: 1.27 $, 10;
index 586113114f0b8cba0b6d00126afbeeaed3fcd58e..0135cda4f8c446ae6ca18ff79545286876610593 100644 (file)
@@ -1,6 +1,6 @@
 package ExtUtils::Mksymlists;
 
-use 5.6.1;
+use 5.006_001;
 use strict qw[ subs refs ];
 # no strict 'vars';  # until filehandles are exempted
 
index 7b664d11397e00308bf972279523e207b4e74cda..ea4ec5e61fbeefec1c972ff09fe125051e060f8f 100644 (file)
@@ -1,6 +1,6 @@
 package ExtUtils::Packlist;
 
-use 5.6.1;
+use 5.006_001;
 use strict;
 use Carp qw();
 our $VERSION = '0.04';
index bf54d9182bddc0310e7bb0cccd75c6b34a0329d8..0ea5963df0b0eb6f6941dee81f67b0bb69ef33df 100644 (file)
@@ -1,6 +1,6 @@
 package Fatal;
 
-use 5.6.1;
+use 5.006_001;
 use Carp;
 use strict;
 our($AUTOLOAD, $Debug, $VERSION);
index e16f87187ecf633cc0d79b48dcc73427360df565..c7657881b9b12dafca728e22fe4551c3451992b3 100644 (file)
@@ -135,7 +135,7 @@ BEGIN {
 
 
 
-use 5.6.0;
+use 5.006;
 use warnings;
 our(@ISA, @EXPORT, $VERSION, $Fileparse_fstype, $Fileparse_igncase);
 require Exporter;
index 35f7906e538a820ede9196785879b3258fa36018..e58e3ecb2c7a19ac8e9ed07e645ec19fdc494929 100644 (file)
@@ -2,7 +2,7 @@ package File::CheckTree;
 
 our $VERSION = '4.1';
 
-require 5.6.0;
+use 5.006;
 require Exporter;
 use warnings;
 
index b83ba625833b9963a9e02f13d165b9519de64d4e..e1d5e7db9146e1e95d5212985ebb8beee5958d8e 100644 (file)
@@ -1,6 +1,6 @@
 package File::Compare;
 
-use 5.6.0;
+use 5.006;
 use strict;
 use warnings;
 our($VERSION, @ISA, @EXPORT, @EXPORT_OK, $Too_Big);
index 7daa3ed60db13ffb4f37b6f713799eebbbda24f5..afb7635f69b82173e9546d3ee673fdb0db6c9862 100644 (file)
@@ -7,7 +7,7 @@
 
 package File::Copy;
 
-use 5.6.0;
+use 5.006;
 use strict;
 use warnings;
 use Carp;
index 1ebfba31845e29b9687cb8d8b5b5c1db2ba1cf6c..de0b5340e42fe6d74c3779e2f928855ef66e9cfb 100644 (file)
@@ -1,7 +1,7 @@
 package File::Find;
+use 5.006;
 use strict;
 use warnings;
-use 5.6.0;
 our $VERSION = '1.02';
 require Exporter;
 require Cwd;
index 7d56d48f28382e64f956bbe12a43f394cb5fc8c5..3560a970a26c2b32b6638f07a3a59e800888cb1f 100644 (file)
@@ -91,7 +91,7 @@ Charles Bailey <F<bailey@newman.upenn.edu>>
 
 =cut
 
-use 5.6.0;
+use 5.006;
 use Carp;
 use File::Basename ();
 use Exporter ();
index aff5d0302050ba6444f6a07906efab69ddbcb658..accae9f559d360da41a4eab748344fc9110fa5ab 100644 (file)
@@ -1,8 +1,9 @@
 package File::stat;
+use 5.006;
+
 use strict;
 use warnings;
 
-use 5.6.0;
 our(@EXPORT, @EXPORT_OK, %EXPORT_TAGS);
 
 our $VERSION = '1.00';
index 51c73becb76bfcc3491b504c14ddd2dba0cc7837..6be2242944044d2ca8fb08bbd001d46b0f899034 100644 (file)
@@ -1,6 +1,6 @@
 package FileHandle;
 
-use 5.6.1;
+use 5.006;
 use strict;
 our($VERSION, @ISA, @EXPORT, @EXPORT_OK);
 
index e4732c1d0ce90aa00446b9a7ff0da535a9f76011..d1ac4f5500d1589fea824213ef1f5c58f5dbbde0 100644 (file)
@@ -7,7 +7,7 @@
 require Exporter;
 package Math::Trig;
 
-use 5.6.1;
+use 5.006;
 use strict;
 
 use Math::Complex qw(:trig);
index 8226a97c93ed9ff01823f5e7f6170803be8c9e65..c963a07afd99fd2addb2005405d6f73a893127fa 100644 (file)
@@ -12,7 +12,7 @@ package Net::Ping;
 # Copyright (c) 2001, Colin McMillen.  All rights reserved.  This
 # program is free software; you may redistribute it and/or modify it
 # under the same terms as Perl itself.
-use 5.6.1;
+use 5.006_001;
 require Exporter;
 
 use strict;
index 44537a24705ce01f2636de4ff1d2d2489f6aff6b..04cbee35a7cea5da11596f10991cafe7dd5508b4 100644 (file)
@@ -1,7 +1,7 @@
 package Net::hostent;
 use strict;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '1.00';
 our(@EXPORT, @EXPORT_OK, %EXPORT_TAGS);
 BEGIN { 
index 210da62c50e22a903fe559b00e681158d6cd2be2..f7d32cb92542fb56af875ccc8bf4825627f3a68f 100644 (file)
@@ -1,7 +1,7 @@
 package Net::netent;
 use strict;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '1.00';
 our(@EXPORT, @EXPORT_OK, %EXPORT_TAGS);
 BEGIN { 
index 5bd0b83837e0f51568192d6c67d4f0782d02a763..2cbccad3cbc36f4bcd4acedce148ff5dad1a43a8 100644 (file)
@@ -1,7 +1,7 @@
 package Net::protoent;
 use strict;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '1.00';
 our(@EXPORT, @EXPORT_OK, %EXPORT_TAGS);
 BEGIN { 
index eaf621a39713c8ad9da8d5b289bf88498e8e1daa..63ae3079fe77508d3513634e38a2f5bf31c22907 100644 (file)
@@ -1,7 +1,7 @@
 package Net::servent;
 use strict;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '1.00';
 our(@EXPORT, @EXPORT_OK, %EXPORT_TAGS);
 BEGIN {
index 5d2f2175d8470932dda93b3d8fd3122c81a9f12c..9762a3aa0bb7be6d1182b463f0832e5f3a299ee2 100644 (file)
@@ -1,5 +1,5 @@
 package Shell;
-use 5.6.1;
+use 5.006_001;
 use strict;
 use warnings;
 our($capture_stderr, $VERSION, $AUTOLOAD);
index c751d5ba71e4aba11d61d51cdf45b475b4be28ec..1cc99b89802ec3640198b890f44e69ff4dbd809f 100644 (file)
@@ -1,6 +1,6 @@
 package Tie::Array;
 
-use 5.6.1;
+use 5.006_001;
 use strict;
 use Carp;
 our $VERSION = '1.02';
index 8e40589c69ac591db89b22095343dfab03c941a7..6fd30d8c748e21fa011ffb2bbc812878d4e88ca3 100644 (file)
@@ -1,6 +1,6 @@
 package Tie::Handle;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '4.1';
 
 =head1 NAME
index 61805849f8ae99109da7dc5071deec0defaf0b23..e99aab13210e0d4627a604ac1593e561e58bf389 100644 (file)
@@ -1,5 +1,5 @@
 package Time::Local;
-require 5.6.0;
+use 5.006;
 require Exporter;
 use Carp;
 use strict;
index 39cfdc2fd7edc2535dc083e60edeb6cdc3b318d8..4e1359b36d90d618239800462dc85fc4fcabe8d3 100644 (file)
@@ -1,8 +1,9 @@
 package Time::gmtime;
 use strict;
+use 5.006_001;
+
 use Time::tm;
 
-use 5.6.1;
 our(@ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS, $VERSION);
 BEGIN { 
     use Exporter   ();
index 549555986325989d287a1c5120417541a8243e0e..c3d9fb36085c8e5cc28076def71cb6ead3e54ac9 100644 (file)
@@ -1,8 +1,9 @@
 package Time::localtime;
 use strict;
+use 5.006_001;
+
 use Time::tm;
 
-use 5.6.1;
 our(@ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS, $VERSION);
 BEGIN {
     use Exporter   ();
index e146ec0bb41ffddf10249b7c8ab843f2c6b4fce4..d9581d8aa8445a95dc03649196c5fa1b51782578 100644 (file)
@@ -1,7 +1,7 @@
 package User::grent;
 use strict;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = '1.00';
 our(@EXPORT, @EXPORT_OK, %EXPORT_TAGS);
 BEGIN { 
index 00391b46d407ad70132779d1566abd38db057ec3..c6d8cca4a78fad00ee3197c3ba60ddc1dce448b0 100644 (file)
@@ -44,7 +44,7 @@ L<fields>
 
 package base;
 
-use 5.6.1;
+use 5.006_001;
 our $VERSION = "1.02";
 
 sub import {
index 5d8f4e7c8f6cf4506dfda45b19b63ea7ee15bb64..031b08e1562085910046ee8165cadcc95bed1253 100755 (executable)
@@ -168,7 +168,7 @@ Tom Christiansen <F<tchrist@mox.perl.com>>, 25 June 1995.
 =cut
 
 use strict;
-use 5.6.0;
+use 5.006;
 use Carp;
 
 our $VERSION = 1.1;
index 5374848d2a2813eac13dd80c32077d91ee8f65af..be2a7aedab42c02fe4adeeaed087c85cff31b564 100644 (file)
@@ -127,7 +127,7 @@ L<perlref/Pseudo-hashes: Using an array as a hash>
 
 =cut
 
-use 5.6.1;
+use 5.006_001;
 use strict;
 no strict 'refs';
 use warnings::register;
index 4abc2d1c08ad745f4c959629534a5eb1c16945c1..a051ba128a1f08057f2e1a2182d23ac08f6b8244 100644 (file)
@@ -1,6 +1,6 @@
 package vars;
 
-require 5.6.0;
+use 5.006;
 
 our $VERSION = '1.01';
 
index fc0d6687262e42958b1f097b792166276761267a..75d7728fda06249cdd58c845a721526f9245afaa 100644 (file)
@@ -112,16 +112,14 @@ to check if you're running a particular version of Perl:
         # new features supported
     }
 
-C<require> and C<use> also have some special magic to support such literals.
-They will be interpreted as a version rather than as a module name:
-
-    require v5.6.0;            # croak if $^V lt v5.6.0
-    use v5.6.0;                        # same, but croaks at compile-time
-
-Alternatively, the C<v> may be omitted if there is more than one dot:
-
-    require 5.6.0;
-    use 5.6.0;
+C<require> and C<use> also have some special magic to support such
+literals, but this particular usage should be avoided because it leads to
+misleading error messages under versions of Perl which don't support vector
+strings.  Using a true version number will ensure correct behavior in all
+versions of Perl:
+
+    require 5.006;    # run time check for v5.6
+    use 5.006_001;    # compile time check for v5.6.1
 
 Also, C<sprintf> and C<printf> support the Perl-specific format flag C<%v>
 to print ordinals of characters in arbitrary strings:
index 0761412f4ad49d23b0c7ee73c1beb719d835ad60..2c198c1d45092af935addfff186947843e86203d 100644 (file)
@@ -3755,19 +3755,23 @@ rename(2) manpage or equivalent system documentation for details.
 
 =item require
 
-Demands some semantics specified by EXPR, or by C<$_> if EXPR is not
-supplied.
+Demands a version of Perl specified by VERSION, or demands some semantics
+specified by EXPR or by C<$_> if EXPR is not supplied.
 
-If a VERSION is specified as a literal of the form v5.6.1,
-demands that the current version of Perl (C<$^V> or $PERL_VERSION) be
-at least as recent as that version, at run time.  (For compatibility
-with older versions of Perl, a numeric argument will also be interpreted
-as VERSION.)  Compare with L</use>, which can do a similar check at
-compile time.
+VERSION may be either a numeric argument such as 5.006, which will be
+compared to C<$]>, or a literal of the form v5.6.1, which will be compared
+to C<$^V> (aka $PERL_VERSION).  A fatal error is produced at run time if
+VERSION is greater than the version of the current Perl interpreter.
+Compare with L</use>, which can do a similar check at compile time.
+
+Specifying VERSION as a literal of the form v5.6.1 should generally be
+avoided, because it leads to misleading error messages under earlier
+versions of Perl which do not support this syntax.  The equivalent numeric
+version should be used instead.
 
     require v5.6.1;    # run time version check
     require 5.6.1;     # ditto
-    require 5.005_03;  # float version allowed for compatibility
+    require 5.006_001; # ditto; preferred for backwards compatibility
 
 Otherwise, demands that a library file be included if it hasn't already
 been included.  The file is included via the do-FILE mechanism, which is
@@ -5640,18 +5644,21 @@ package.  It is exactly equivalent to
 
 except that Module I<must> be a bareword.
 
-VERSION, which can be specified as a literal of the form v5.6.1, demands
-that the current version of Perl (C<$^V> or $PERL_VERSION) be at least
-as recent as that version.  (For compatibility with older versions of Perl,
-a numeric literal will also be interpreted as VERSION.)  If the version
-of the running Perl interpreter is less than VERSION, then an error
-message is printed and Perl exits immediately without attempting to
-parse the rest of the file.  Compare with L</require>, which can do a
-similar check at run time.
+VERSION may be either a numeric argument such as 5.006, which will be
+compared to C<$]>, or a literal of the form v5.6.1, which will be compared
+to C<$^V> (aka $PERL_VERSION.  A fatal error is produced if VERSION is
+greater than the version of the current Perl interpreter; Perl will not
+attempt to parse the rest of the file.  Compare with L</require>, which can
+do a similar check at run time.
+
+Specifying VERSION as a literal of the form v5.6.1 should generally be
+avoided, because it leads to misleading error messages under earlier
+versions of Perl which do not support this syntax.  The equivalent numeric
+version should be used instead.
 
     use v5.6.1;                # compile time version check
     use 5.6.1;         # ditto
-    use 5.005_03;      # float version allowed for compatibility
+    use 5.006_001;     # ditto; preferred for backwards compatibility
 
 This is often useful if you need to check the current Perl version before
 C<use>ing library modules that have changed in incompatible ways from
index 0b7daa10d00c77102afdfbc933dec73c69d6d8a4..5d2d10f94c9c55e750f74a620beb41ae1f2ce905 100644 (file)
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -3078,7 +3078,7 @@ PP(pp_require)
                if (sver == 0 && (rev > 5 || (rev == 5 && ver >= 100))) {
                    DIE(aTHX_ "Perl v%"UVuf".%"UVuf".%"UVuf" required--"
                        "this is only v%d.%d.%d, stopped"
-                       " (did you mean v%"UVuf".%"UVuf".0?)",
+                       " (did you mean v%"UVuf".%03"UVuf"?)",
                        rev, ver, sver, PERL_REVISION, PERL_VERSION,
                        PERL_SUBVERSION, rev, ver/100);
                }
index 5637818fa1e21151937aa57596d4cbb6a2ba48f5..d135bc8c45c5b7251f9bf6dbeda3053008f3bde9 100644 (file)
@@ -129,7 +129,7 @@ while (<>) {
     if ( open(PM, ">$newname") ) {
         print PM <<"END";
 package $newpack;
-require 5.6.0;
+use 5.006;
 require Exporter;
 $carp
 \@ISA = qw(Exporter);