diff options
author | Stuart Henderson <sthen@cvs.openbsd.org> | 2013-03-25 20:09:38 +0000 |
---|---|---|
committer | Stuart Henderson <sthen@cvs.openbsd.org> | 2013-03-25 20:09:38 +0000 |
commit | 39cf45909bf0404f27de64c367d8dcdf37147915 (patch) | |
tree | 70cd1ac1a81c3cb8fa62c79486459e5d00dabf46 /gnu/usr.bin/perl | |
parent | 38b9480a88793314fc621bfec3da592ab7cc1b67 (diff) |
import perl 5.16.3 from CPAN - worked on by Andrew Fresh and myself
Diffstat (limited to 'gnu/usr.bin/perl')
29 files changed, 168 insertions, 798 deletions
diff --git a/gnu/usr.bin/perl/cpan/CPAN-Meta-YAML/t/15_multibyte.t b/gnu/usr.bin/perl/cpan/CPAN-Meta-YAML/t/15_multibyte.t index 5adbc1e8785..8e679f5fda0 100644 --- a/gnu/usr.bin/perl/cpan/CPAN-Meta-YAML/t/15_multibyte.t +++ b/gnu/usr.bin/perl/cpan/CPAN-Meta-YAML/t/15_multibyte.t @@ -10,7 +10,7 @@ BEGIN { use File::Spec::Functions ':ALL'; use t::lib::Test; -use Test::More tests(0, 1, 6); +use Test::More tests(0, 1, 5); use CPAN::Meta::YAML; @@ -41,12 +41,11 @@ SKIP: { SKIP: { unless ( CPAN::Meta::YAML::HAVE_UTF8() ) { - skip("no utf8 support", 2 ); + skip("no utf8 support", 1 ); } eval { utf8::is_utf8('') }; if ( $@ ) { - skip("no is_utf8 to test with until 5.8.1", 2); + skip("no is_utf8 to test with until 5.8.1", 1); } ok( utf8::is_utf8($yaml->[0]->{author}), "utf8 decoded" ); - is( length($yaml->[0]->{author}), 39, "utf8 decoded as characters" ); } diff --git a/gnu/usr.bin/perl/cpan/CPAN-Meta/Changes b/gnu/usr.bin/perl/cpan/CPAN-Meta/Changes index e866b7611ff..61d6b27d675 100644 --- a/gnu/usr.bin/perl/cpan/CPAN-Meta/Changes +++ b/gnu/usr.bin/perl/cpan/CPAN-Meta/Changes @@ -1,34 +1,5 @@ Revision history for CPAN-Meta -2.120921 2012-04-01 15:20:24 Europe/Paris - - [REMOVED] - - - CPAN::Meta::Requirements has been split out into its own distribution - so it can be used by CPAN.pm without requiring all of CPAN::Meta - -2.120920 2012-04-01 11:30:43 Europe/Paris - - [ADDED] - - - CPAN::Meta::Requirements now has a 'requirements_for_module' method - to retrieve a version requirements string for a specific module - [Leon Timmermans] - - [OTHER] - - - Parse::CPAN::Meta prerequisite bumped to 1.4403 - - JSON::PP prerequisites bumped to 2.27200 - - CPAN::Meta::YAML prerequisite bumped to 0.008 - -2.120900 2012-03-30 13:15:15 Europe/Paris - - [BUGFIX] - - - CPAN::Meta::Requirements now treats undef requirements given to - from_string_hash() as '0' and warns about it; add_string_requirements() - dies if it does not get a requirements string to parse - 2.120630 2012-03-03 14:48:35 EST5EDT [BUGFIX] diff --git a/gnu/usr.bin/perl/cpan/Pod-LaTeX/lib/Pod/LaTeX.pm b/gnu/usr.bin/perl/cpan/Pod-LaTeX/lib/Pod/LaTeX.pm index fc6d99dd979..f4b1aaf97b9 100644 --- a/gnu/usr.bin/perl/cpan/Pod-LaTeX/lib/Pod/LaTeX.pm +++ b/gnu/usr.bin/perl/cpan/Pod-LaTeX/lib/Pod/LaTeX.pm @@ -28,14 +28,12 @@ use strict; require Pod::ParseUtils; use base qw/ Pod::Select /; -use if $] > 5.017, 'deprecate'; - # use Data::Dumper; # for debugging use Carp; use vars qw/ $VERSION %HTML_Escapes @LatexSections /; -$VERSION = '0.61'; +$VERSION = '0.60'; # Definitions of =headN -> latex mapping @LatexSections = (qw/ diff --git a/gnu/usr.bin/perl/cpan/Pod-Perldoc/lib/perldoc.pod b/gnu/usr.bin/perl/cpan/Pod-Perldoc/lib/perldoc.pod index 55febc4bf94..42a9eab4cdb 100644 --- a/gnu/usr.bin/perl/cpan/Pod-Perldoc/lib/perldoc.pod +++ b/gnu/usr.bin/perl/cpan/Pod-Perldoc/lib/perldoc.pod @@ -5,28 +5,28 @@ perldoc - Look up Perl documentation in Pod format. =head1 SYNOPSIS - perldoc [-h] [-D] [-t] [-u] [-m] [-l] [-F] - [-i] [-V] [-T] [-r] - [-d destination_file] - [-o formatname] - [-M FormatterClassName] - [-w formatteroption:value] - [-n nroff-replacement] - [-X] - [-L language_code] + B<perldoc> [B<-h>] [B<-D>] [B<-t>] [B<-u>] [B<-m>] [B<-l>] [B<-F>] + [B<-i>] [B<-V>] [B<-T>] [B<-r>] + [B<-dI<destination_file>>] + [B<-oI<formatname>>] + [B<-MI<FormatterClassName>>] + [B<-wI<formatteroption:value>>] + [B<-n>I<nroff-replacement>] + [B<-X>] + [B<-L> I<language_code>] PageName|ModuleName|ProgramName|URL Examples: - perldoc -f BuiltinFunction + B<perldoc> B<-f> BuiltinFunction - perldoc -L it -f BuiltinFunction + B<perldoc> B<-L> it B<-f> BuiltinFunction - perldoc -q FAQ Keyword + B<perldoc> B<-q> FAQ Keyword - perldoc -L fr -q FAQ Keyword + B<perldoc> B<-L> fr B<-q> FAQ Keyword - perldoc -v PerlVariable + B<perldoc> B<-v> PerlVariable See below for more description of the switches. @@ -116,7 +116,7 @@ Examples: =item B<-T> This specifies that the output is not to be sent to a pager, but is to -be sent directly to STDOUT. +be sent right to STDOUT. =item B<-d> I<destination-filename> @@ -219,14 +219,15 @@ drop privileges by setting the effective and real IDs to nobody's or nouser's account, or -2 if unavailable. If it cannot relinquish its privileges, it will not run. + =head1 ENVIRONMENT Any switches in the C<PERLDOC> environment variable will be used before the command line arguments. -Useful values for C<PERLDOC> include C<-oterm>, C<-otext>, C<-ortf>, +Useful values for C<PERLDOC> include C<-oman>, C<-otext>, C<-otk>, C<-ortf>, C<-oxml>, and so on, depending on what modules you have on hand; or -the formatter class may be specified exactly with C<-MPod::Perldoc::ToTerm> +the formatter class may be specified exactly with C<-MPod::Perldoc::ToMan> or the like. C<perldoc> also searches directories @@ -235,12 +236,6 @@ defined) and C<PATH> environment variables. (The latter is so that embedded pods for executables, such as C<perldoc> itself, are available.) -In directories where either C<Makefile.PL> or C<Build.PL> exist, C<perldoc> -will add C<.> and C<lib> first to its search path, and as long as you're not -the superuser will add C<blib> too. This is really helpful if you're working -inside of a build directory and want to read through the docs even if you -have a version of a module previously installed. - C<perldoc> will use, in order of preference, the pager defined in C<PERLDOC_PAGER>, C<MANPAGER>, or C<PAGER> before trying to find a pager on its own. (C<MANPAGER> is not used if C<perldoc> was told to display @@ -249,7 +244,7 @@ plain text or unformatted pod.) One useful value for C<PERLDOC_PAGER> is C<less -+C -E>. Having PERLDOCDEBUG set to a positive integer will make perldoc emit -even more descriptive output than the C<-D> switch does; the higher the +even more descriptive output than the C<-v> switch does; the higher the number, the more it emits. diff --git a/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST b/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST index 93e9ac84180..ee35512034d 100644 --- a/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST +++ b/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST @@ -76,7 +76,6 @@ t/aggregator.t t/bailout.t t/base.t t/callbacks.t -t/compat/env_opts.t t/compat/env.t t/compat/failure.t t/compat/inc-propagation.t @@ -126,7 +125,6 @@ t/multiplexer.t t/nested.t t/nofork-mux.t t/nofork.t -t/nowarn.t t/object.t t/parse.t t/parser-config.t @@ -234,4 +232,3 @@ xt/author/pod.t xt/author/stdin.t xt/perls/harness_perl.t xt/perls/sample-tests/perl_version -META.json diff --git a/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST.CUMMULATIVE b/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST.CUMMULATIVE index bd2b6f03141..c0e58b04361 100644 --- a/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST.CUMMULATIVE +++ b/gnu/usr.bin/perl/cpan/Test-Harness/MANIFEST.CUMMULATIVE @@ -156,7 +156,6 @@ t/compat/040-test-harness-compat.t t/compat/060-version.t t/compat/base.t t/compat/callback.t -t/compat/env.opts.t t/compat/env.t t/compat/failure.t t/compat/from_line.t @@ -221,7 +220,6 @@ t/multiplexer.t t/nested.t t/nofork-mux.t t/nofork.t -t/nowarn.t t/object.t t/parse.t t/parser-config.t diff --git a/gnu/usr.bin/perl/dist/B-Deparse/t/core.t b/gnu/usr.bin/perl/dist/B-Deparse/t/core.t index 58540f88351..62ff862e043 100644 --- a/gnu/usr.bin/perl/dist/B-Deparse/t/core.t +++ b/gnu/usr.bin/perl/dist/B-Deparse/t/core.t @@ -1,31 +1,5 @@ #!./perl -# Test the core keywords. -# -# Initially this test file just checked that CORE::foo got correctly -# deparsed as CORE::foo, hence the name. It's since been expanded -# to fully test both CORE:: verses none, plus that any arguments -# are correctly deparsed. It also cross-checks against regen/keywords.pl -# to make sure we've tested all keywords, and with the correct strength. -# -# A keyword can be either weak or strong. Strong keywords can never be -# overridden, while weak ones can. So deparsing of weak keywords depends -# on whether a sub of that name has been created: -# -# for both: keyword(..) deparsed as keyword(..) -# for weak: CORE::keyword(..) deparsed as CORE::keyword(..) -# for strong: CORE::keyword(..) deparsed as keyword(..) -# -# Three permutations of lex/nonlex args are checked for: -# -# foo($a,$b,$c,...) -# foo(my $a,$b,$c,...) -# my ($a,$b,$c,...); foo($a,$b,$c,...) -# -# Note that tests for prefixing feature.pm-enabled keywords with CORE:: when -# feature.pm is not enabled are in deparse.t, as they fit that format better. - - BEGIN { require Config; if (($Config::Config{extensions} !~ /\bB\b/) ){ @@ -36,587 +10,101 @@ BEGIN { use strict; use Test::More; -plan tests => 2063; - use feature (sprintf(":%vd", $^V)); # to avoid relying on the feature # logic to add CORE:: -use B::Deparse; -my $deparse = new B::Deparse; - -my %SEEN; -my %SEEN_STRENGH; - -# for a given keyword, create a sub of that name, then -# deparse "() = $expr", and see if it matches $expected_expr - -sub testit { - my ($keyword, $expr, $expected_expr) = @_; - - $expected_expr //= $expr; - $SEEN{$keyword} = 1; - - - # lex=0: () = foo($a,$b,$c) - # lex=1: my ($a,$b); () = foo($a,$b,$c) - # lex=2: () = foo(my $a,$b,$c) - for my $lex (0, 1, 2) { - if ($lex) { - next if $keyword =~ /local|our|state|my/; - # XXX glob(my $x) incorrectly becomes <my $x> - next if $keyword eq 'glob'; - } - my $vars = $lex == 1 ? 'my($a, $b, $c, $d, $e);' . "\n " : ""; - - if ($lex == 2) { - my $repl = 'my $a'; - if ($expr =~ /\bmap\(\$a|CORE::(chomp|chop|lstat|stat)\b/) { - # for some reason only these do: - # 'foo my $a, $b,' => foo my($a), $b, ... - # the rest don't parenthesize the my var. - $repl = 'my($a)'; - } - s/\$a/$repl/ for $expr, $expected_expr; - } - - my $desc = "$keyword: lex=$lex $expr => $expected_expr"; - - - my $code_ref; - { - package test; - use subs (); - import subs $keyword; - $code_ref = eval "no strict 'vars'; sub { ${vars}() = $expr }" - or die "$@ in $expr"; - } - - my $got_text = $deparse->coderef2text($code_ref); - - unless ($got_text =~ /^{ - package test; - use strict 'refs', 'subs'; - use feature [^\n]+ - \Q$vars\E\(\) = (.*) -}/s) { - ::fail($desc); - ::diag("couldn't extract line from boilerplate\n"); - ::diag($got_text); - return; - } - - my $got_expr = $1; - is $got_expr, $expected_expr, $desc; - } -} +# Many functions appear in multiple lists, so that shift() and shift(foo) +# are both tested. +# For lists, we test 0 to 2 arguments. +my @nary = ( + # nullary functions + [qw( abs alarm break chr cos chop close chdir chomp chmod chown + chroot caller continue die dump exp exit exec endgrent + endpwent endnetent endhostent endservent + endprotoent evalbytes fc fork glob + getppid getpwent getprotoent gethostent getnetent getservent + getgrent getlogin getc gmtime hex int lc log lstat length + lcfirst localtime mkdir ord oct pop quotemeta ref rand + rmdir reset reverse readlink select setpwent setgrent + shift sin sleep sqrt srand stat __SUB__ system tell time times + uc utime umask unlink ucfirst wantarray warn wait write )], + # unary + [qw( abs alarm bless binmode chr cos chop close chdir chomp + chmod chown chroot closedir die do dump exp exit exec + each evalbytes fc fileno getpgrp getpwnam getpwuid getpeername + getprotobyname getprotobynumber gethostbyname + getnetbyname getsockname getgrnam getgrgid + getc glob gmtime hex int join keys kill lc + log lock lstat length lcfirst localtime + mkdir ord oct open pop push pack quotemeta + ref rand rmdir reset reverse readdir readlink + rewinddir select setnetent sethostent setservent + setprotoent shift sin sleep sprintf splice sqrt + srand stat system tell tied telldir uc utime umask + unpack unlink unshift untie ucfirst values warn write )], + # binary, but not infix + [qw( atan2 accept bind binmode chop chomp chmod chown crypt + connect die exec flock formline getpriority gethostbyaddr + getnetbyaddr getservbyname getservbyport index join kill + link listen mkdir msgget open opendir push pack pipe + rename rindex reverse seekdir semop setpgrp shutdown + sprintf splice substr system symlink syscall syswrite + tie truncate utime unpack unlink warn waitpid )], + # ternary + [qw( fcntl getsockopt index ioctl join kill msgctl + msgsnd open push pack read rindex seek send + semget setpriority shmctl shmget sprintf splice + substr sysopen sysread sysseek syswrite tie vec )], + # quaternary + [qw( open read recv send select semctl setsockopt shmread + shmwrite socket splice substr sysopen sysread syswrite tie )], + # quinary + [qw( msgrcv open socketpair splice )] +); -# Deparse can't distinguish 'and' from '&&' etc -my %infix_map = qw(and && or ||); - - -# test a keyword that is a binary infix operator, like 'cmp'. -# $parens - "$a op $b" is deparsed as "($a op $b)" -# $strong - keyword is strong - -sub do_infix_keyword { - my ($keyword, $parens, $strong) = @_; - $SEEN_STRENGH{$keyword} = $strong; - my $expr = "(\$a $keyword \$b)"; - my $nkey = $infix_map{$keyword} // $keyword; - my $expr = "(\$a $keyword \$b)"; - my $exp = "\$a $nkey \$b"; - $exp = "($exp)" if $parens; - $exp .= ";"; - # with infix notation, a keyword is always interpreted as core, - # so no need for Deparse to disambiguate with CORE:: - testit $keyword, "(\$a CORE::$keyword \$b)", $exp; - testit $keyword, "(\$a $keyword \$b)", $exp; - if (!$strong) { - testit $keyword, "$keyword(\$a, \$b)", "$keyword(\$a, \$b);"; - } -} - -# test a keyword that is as tandard op/function, like 'index(...)'. -# narg - how many args to test it with -# $parens - "foo $a, $b" is deparsed as "foo($a, $b)" -# $dollar - an extra '$_' arg will appear in the deparsed output -# $strong - keyword is strong - - -sub do_std_keyword { - my ($keyword, $narg, $parens, $dollar, $strong) = @_; - - $SEEN_STRENGH{$keyword} = $strong; +use B::Deparse; +my $deparse = new B::Deparse; - for my $core (0,1) { # if true, add CORE:: to keyword being deparsed - my @code; - for my $do_exp(0, 1) { # first create expr, then expected-expr - my @args = map "\$$_", (undef,"a".."z")[1..$narg]; - push @args, '$_' if $dollar && $do_exp && ($strong || $core); - my $args = join(', ', @args); - $args = ((!$core && !$strong) || $parens) - ? "($args)" - : @args ? " $args" : ""; - push @code, (($core && !($do_exp && $strong)) ? "CORE::" : "") - . "$keyword$args;"; - } - testit $keyword, @code; # code[0]: to run; code[1]: expected - } +sub CORE_test { + my($keyword,$expr,$name) = @_; + package test; + use subs (); + import subs $keyword; + ::like + $deparse->coderef2text( + eval "no strict 'vars'; sub { () = $expr }" or die "$@in $expr" + ), + qr/\sCORE::$keyword.*;/, + $name||$keyword } - -while (<DATA>) { - chomp; - s/#.*//; - next unless /\S/; - - my @fields = split; - die "not 3 fields" unless @fields == 3; - my ($keyword, $args, $flags) = @fields; - - $args = '012' if $args eq '@'; - - my $parens = $flags =~ s/p//; - my $invert1 = $flags =~ s/1//; - my $dollar = $flags =~ s/\$//; - my $strong = $flags =~ s/\+//; - die "unrecognised flag(s): '$flags'" unless $flags =~ /^-?$/; - - if ($args eq 'B') { # binary infix - die "$keyword: binary (B) op can't have '\$' flag\\n" if $dollar; - die "$keyword: binary (B) op can't have '1' flag\\n" if $invert1; - do_infix_keyword($keyword, $parens, $strong); - } - else { - my @narg = split //, $args; - for my $n (0..$#narg) { - my $narg = $narg[$n]; - my $p = $parens; - $p = !$p if ($n == 0 && $invert1); - do_std_keyword($keyword, $narg, $p, (!$n && $dollar), $strong); - } - } +for my $argc(0..$#nary) { + for(@{$nary[$argc]}) { + CORE_test + $_, + "CORE::$_(" . join(',',map "\$$_", (undef,"a".."z")[1..$argc]) . ")", + "$_, $argc argument" . "s"x($argc != 1); + } } - # Special cases - -testit dbmopen => 'CORE::dbmopen(%foo, $bar, $baz);'; -testit dbmclose => 'CORE::dbmclose %foo;'; - -testit delete => 'CORE::delete $h{\'foo\'};', 'delete $h{\'foo\'};'; -testit delete => 'delete $h{\'foo\'};', 'delete $h{\'foo\'};'; - -# do is listed as strong, but only do { block } is strong; -# do $file is weak, so test it separately here -testit do => 'CORE::do $a;'; -testit do => 'do $a;', 'do($a);'; -testit do => 'CORE::do { 1 }', - "do {\n 1\n };"; -testit do => 'do { 1 };', - "do {\n 1\n };"; - -testit each => 'CORE::each %bar;'; - -testit eof => 'CORE::eof();'; - -testit exists => 'CORE::exists $h{\'foo\'};', 'exists $h{\'foo\'};'; -testit exists => 'exists $h{\'foo\'};', 'exists $h{\'foo\'};'; - -testit exec => 'CORE::exec($foo $bar);'; - -# glob($x) gets deparsed as glob("$x"). -# Whether this is correct, I don't know; but I didn't want -# to start messing with the whole glob/readline/<> mess - DAPM. -testit glob => 'glob;', 'glob("$_");'; -testit glob => 'CORE::glob;', 'glob("$_");'; -testit glob => 'glob $a;', 'glob("$a");'; -testit glob => 'CORE::glob $a;', 'glob("$a");'; - -testit grep => 'CORE::grep { $a } $b, $c', 'grep({$a;} $b, $c);'; - -testit keys => 'CORE::keys %bar;'; - -testit map => 'CORE::map { $a } $b, $c', 'map({$a;} $b, $c);'; - -testit not => '3 unless CORE::not $a && $b;'; - -testit readline => 'CORE::readline $a . $b;'; - -testit readpipe => 'CORE::readpipe $a + $b;'; - -testit reverse => 'CORE::reverse sort(@foo);'; - -# note that the test does '() = split...' which is why the -# limit is optimised to 1 -testit split => 'split;', q{split(' ', $_, 1);}; -testit split => 'CORE::split;', q{split(' ', $_, 1);}; -testit split => 'split $a;', q{split(/$a/u, $_, 1);}; -testit split => 'CORE::split $a;', q{split(/$a/u, $_, 1);}; -testit split => 'split $a, $b;', q{split(/$a/u, $b, 1);}; -testit split => 'CORE::split $a, $b;', q{split(/$a/u, $b, 1);}; -testit split => 'split $a, $b, $c;', q{split(/$a/u, $b, $c);}; -testit split => 'CORE::split $a, $b, $c;', q{split(/$a/u, $b, $c);}; - -testit sub => 'CORE::sub { $a, $b }', - "sub {\n \$a, \$b;\n }\n ;"; - -testit system => 'CORE::system($foo $bar);'; - -testit values => 'CORE::values %bar;'; - - -# XXX These are deparsed wrapped in parens. -# whether they should be, I don't know! - -testit dump => '(CORE::dump);'; -testit dump => '(CORE::dump FOO);'; -testit goto => '(CORE::goto);', '(goto);'; -testit goto => '(CORE::goto FOO);', '(goto FOO);'; -testit last => '(CORE::last);', '(last);'; -testit last => '(CORE::last FOO);', '(last FOO);'; -testit next => '(CORE::next);', '(next);'; -testit next => '(CORE::next FOO);', '(next FOO);'; -testit redo => '(CORE::redo);', '(redo);'; -testit redo => '(CORE::redo FOO);', '(redo FOO);'; -testit redo => '(CORE::redo);', '(redo);'; -testit redo => '(CORE::redo FOO);', '(redo FOO);'; -testit return => '(return);', '(return);'; -testit return => '(CORE::return);', '(return);'; - -# these are the keywords I couldn't think how to test within this framework - -my %not_tested = map { $_ => 1} qw( - __DATA__ - __END__ - __FILE__ - __LINE__ - __PACKAGE__ - __SUB__ - AUTOLOAD - BEGIN - CHECK - CORE - DESTROY - END - INIT - UNITCHECK - default - else - elsif - for - foreach - format - given - if - m - no - package - q - qq - qr - qw - qx - require - s - tr - unless - until - use - when - while - y -); - - - -# Sanity check against keyword data: -# make sure we haven't missed any keywords, -# and that we got the strength right. - -SKIP: -{ - skip "sanity checks when not PERL_CORE", 1 unless defined $ENV{PERL_CORE}; - my $count = 0; - my $file = '../../regen/keywords.pl'; - my $pass = 1; - if (open my $fh, '<', $file) { - while (<$fh>) { - last if /^__END__$/; - } - while (<$fh>) { - next unless /^([+\-])(\w+)$/; - my ($strength, $key) = ($1, $2); - $strength = ($strength eq '+') ? 1 : 0; - $count++; - if (!$SEEN{$key} && !$not_tested{$key}) { - diag("keyword '$key' seen in $file, but not tested here!!"); - $pass = 0; - } - if (exists $SEEN_STRENGH{$key} and $SEEN_STRENGH{$key} != $strength) { - diag("keyword '$key' strengh as seen in $file doen't match here!!"); - $pass = 0; - } - } - } - else { - diag("Can't open $file: $!"); - $pass = 0; - } - # insanity check - if ($count < 200) { - diag("Saw $count keywords: less than 200!"); - $pass = 0; - } - ok($pass, "sanity checks"); -} - - - -__DATA__ -# -# format: -# keyword args flags -# -# args consists of: -# * one of more digits indictating which lengths of args the function accepts, -# * or 'B' to indiate a binary infix operator, -# * or '@' to indicate a list function. -# -# Flags consists of the following (or '-' if no flags): -# + : strong keyword: can't be overrriden -# p : the args are parenthesised on deparsing; -# 1 : parenthesising of 1st arg length is inverted -# so '234 p1' means: foo a1,a2; foo(a1,a2,a3); foo(a1,a2,a3,a4) -# $ : on the first argument length, there is an implicit extra -# '$_' arg which will appear on deparsing; -# e.g. 12p$ will be tested as: foo(a1); foo(a1,a2); -# and deparsed as: foo(a1, $_); foo(a1,a2); -# -# XXX Note that we really should get this data from regen/keywords.pl -# and regen/opcodes (augmented if necessary), rather than duplicating it -# here. - -__SUB__ 0 - -abs 01 $ -accept 2 p -alarm 01 $ -and B - -atan2 2 p -bind 2 p -binmode 12 p -bless 1 p -break 0 - -caller 0 - -chdir 01 - -chmod @ p1 -chomp @ $ -chop @ $ -chown @ p1 -chr 01 $ -chroot 01 $ -close 01 - -closedir 1 - -cmp B - -connect 2 p -continue 0 - -cos 01 $ -crypt 2 p -# dbmopen handled specially -# dbmclose handled specially -defined 01 $+ -# delete handled specially -die @ p1 -# do handled specially -# dump handled specially -each 1 - # also tested specially -endgrent 0 - -endhostent 0 - -endnetent 0 - -endprotoent 0 - -endpwent 0 - -endservent 0 - -eof 01 - # also tested specially -eq B - -eval 01 $+ -evalbytes 01 $ -exec @ p1 # also tested specially -# exists handled specially -exit 01 - -exp 01 $ -fc 01 $ -fcntl 3 p -fileno 1 - -flock 2 p -fork 0 - -formline 2 p -ge B - -getc 01 - -getgrent 0 - -getgrgid 1 - -getgrnam 1 - -gethostbyaddr 2 p -gethostbyname 1 - -gethostent 0 - -getlogin 0 - -getnetbyaddr 2 p -getnetbyname 1 - -getnetent 0 - -getpeername 1 - -getpgrp 1 - -getppid 0 - -getpriority 2 p -getprotobyname 1 - -getprotobynumber 1 p -getprotoent 0 - -getpwent 0 - -getpwnam 1 - -getpwuid 1 - -getservbyname 2 p -getservbyport 2 p -getservent 0 - -getsockname 1 - -getsockopt 3 p -# given handled specially -grep 123 p+ # also tested specially -# glob handled specially -# goto handled specially -gmtime 01 - -gt B - -hex 01 $ -index 23 p -int 01 $ -ioctl 3 p -join 123 p -keys 1 - # also tested specially -kill 123 p -# last handled specially -lc 01 $ -lcfirst 01 $ -le B - -length 01 $ -link 2 p -listen 2 p -local 1 p+ -localtime 01 - -lock 1 - -log 01 $ -lstat 01 $ -lt B - -map 123 p+ # also tested specially -mkdir @ p$ -msgctl 3 p -msgget 2 p -msgrcv 5 p -msgsnd 3 p -my 123 p+ # skip with 0 args, as my() => () -ne B - -# next handled specially -# not handled specially -oct 01 $ -open 12345 p -opendir 2 p -or B - -ord 01 $ -our 123 p+ # skip with 0 args, as our() => () -pack 123 p -pipe 2 p -pop 01 1 -pos 01 $+ -print @ p$+ -printf @ p$+ -prototype 1 + -push 123 p -quotemeta 01 $ -rand 01 - -read 34 p -readdir 1 - -# readline handled specially -readlink 01 $ -# readpipe handled specially -recv 4 p -# redo handled specially -ref 01 $ -rename 2 p -# XXX This code prints 'Undefined subroutine &main::require called': -# use subs (); import subs 'require'; -# eval q[no strict 'vars'; sub { () = require; }]; print $@; -# so disable for now -#require 01 $+ -reset 01 - -# return handled specially -reverse @ p1 # also tested specially -rewinddir 1 - -rindex 23 p -rmdir 01 $ -say @ p$+ -scalar 1 + -seek 3 p -seekdir 2 p -select 014 p1 -semctl 4 p -semget 3 p -semop 2 p -send 34 p -setgrent 0 - -sethostent 1 - -setnetent 1 - -setpgrp 2 p -setpriority 3 p -setprotoent 1 - -setpwent 0 - -setservent 1 - -setsockopt 4 p -shift 01 1 -shmctl 3 p -shmget 3 p -shmread 4 p -shmwrite 4 p -shutdown 2 p -sin 01 $ -sleep 01 - -socket 4 p -socketpair 5 p -sort @ p+ -# split handled specially -splice 12345 p -sprintf 123 p -sqrt 01 $ -srand 01 - -stat 01 $ -state 123 p+ # skip with 0 args, as state() => () -study 01 $+ -# sub handled specially -substr 234 p -symlink 2 p -syscall 2 p -sysopen 34 p -sysread 34 p -sysseek 3 p -system @ p1 # also tested specially -syswrite 234 p -tell 01 - -telldir 1 - -tie 234 p -tied 1 - -time 0 - -times 0 - -truncate 2 p -uc 01 $ -ucfirst 01 $ -umask 01 - -undef 01 + -unlink @ p$ -unpack 12 p$ -unshift 1 p -untie 1 - -utime @ p1 -values 1 - # also tested specially -vec 3 p -wait 0 - -waitpid 2 p -wantarray 0 - -warn @ p1 -write 01 - -x B - -xor B p +CORE_test dbmopen => 'CORE::dbmopen %foo, $bar, $baz'; +CORE_test dbmclose => 'CORE::dbmclose %foo'; +CORE_test eof => 'CORE::eof $foo', 'eof $arg'; +CORE_test eof => 'CORE::eof', 'eof'; +CORE_test eof => 'CORE::eof()', 'eof()'; +CORE_test exec => 'CORE::exec $foo $bar', 'exec PROGRAM LIST'; +CORE_test each => 'CORE::each %bar', 'each %hash'; +CORE_test keys => 'CORE::keys %bar', 'keys %hash'; +CORE_test reverse => 'CORE::reverse sort @foo', 'reverse sort'; +CORE_test system => 'CORE::system $foo $bar', 'system PROGRAM LIST'; +CORE_test values => 'CORE::values %bar', 'values %hash'; +CORE_test not => '3 unless CORE::not $a && $b', 'not'; +CORE_test readline => 'CORE::readline $a.$b', 'readline'; +CORE_test readpipe => 'CORE::readpipe $a+$b', 'readpipe'; + +# Tests for prefixing feature.pm-enabled keywords with CORE:: when +# feature.pm is not enabled are in deparse.t, as they fit that for- +# mat better. + +done_testing(); diff --git a/gnu/usr.bin/perl/dist/Cwd/Cwd.pm b/gnu/usr.bin/perl/dist/Cwd/Cwd.pm index 8886c67b4c5..a48d20547f8 100644 --- a/gnu/usr.bin/perl/dist/Cwd/Cwd.pm +++ b/gnu/usr.bin/perl/dist/Cwd/Cwd.pm @@ -171,7 +171,7 @@ use strict; use Exporter; use vars qw(@ISA @EXPORT @EXPORT_OK $VERSION); -$VERSION = '3.40'; +$VERSION = '3.39_02'; my $xs_version = $VERSION; $VERSION =~ tr/_//; @@ -624,8 +624,8 @@ sub fast_abs_path { # Detaint else we'll explode in taint mode. This is safe because # we're not doing anything dangerous with it. - ($path) = $path =~ /(.*)/s; - ($cwd) = $cwd =~ /(.*)/s; + ($path) = $path =~ /(.*)/; + ($cwd) = $cwd =~ /(.*)/; unless (-e $path) { _croak("$path: No such file or directory"); diff --git a/gnu/usr.bin/perl/dist/Cwd/Cwd.xs b/gnu/usr.bin/perl/dist/Cwd/Cwd.xs index 3940006e626..539311662c5 100644 --- a/gnu/usr.bin/perl/dist/Cwd/Cwd.xs +++ b/gnu/usr.bin/perl/dist/Cwd/Cwd.xs @@ -247,7 +247,7 @@ return FALSE #ifndef getcwd_sv /* Taken from perl 5.8's util.c */ #define getcwd_sv(a) Perl_getcwd_sv(aTHX_ a) -int Perl_getcwd_sv(pTHX_ SV *sv) +int Perl_getcwd_sv(pTHX_ register SV *sv) { #ifndef PERL_MICRO diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec.pm index 6062c015179..782e28425b7 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec.pm @@ -3,7 +3,7 @@ package File::Spec; use strict; use vars qw(@ISA $VERSION); -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; my %module = (MacOS => 'Mac', @@ -331,7 +331,7 @@ splitpath(), splitdir(), catpath() and catdir() by Barrie Slaymaker. =head1 COPYRIGHT -Copyright (c) 2004-2013 by the Perl 5 Porters. All rights reserved. +Copyright (c) 2004-2010 by the Perl 5 Porters. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Cygwin.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Cygwin.pm index b27f7b15f19..b63b85f6cda 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Cygwin.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Cygwin.pm @@ -4,7 +4,7 @@ use strict; use vars qw(@ISA $VERSION); require File::Spec::Unix; -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; @ISA = qw(File::Spec::Unix); diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Epoc.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Epoc.pm index e7faa16086a..50304ffed06 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Epoc.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Epoc.pm @@ -3,7 +3,7 @@ package File::Spec::Epoc; use strict; use vars qw($VERSION @ISA); -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; require File::Spec::Unix; diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Functions.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Functions.pm index f5b9046aa5e..454a5b30898 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Functions.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Functions.pm @@ -5,7 +5,7 @@ use strict; use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS $VERSION); -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; require Exporter; diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Mac.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Mac.pm index 7f42171bc92..57d1d3efb33 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Mac.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Mac.pm @@ -4,7 +4,7 @@ use strict; use vars qw(@ISA $VERSION); require File::Spec::Unix; -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; @ISA = qw(File::Spec::Unix); diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/OS2.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/OS2.pm index 7f60d68927a..5461cf7a701 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/OS2.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/OS2.pm @@ -4,7 +4,7 @@ use strict; use vars qw(@ISA $VERSION); require File::Spec::Unix; -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; @ISA = qw(File::Spec::Unix); diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Unix.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Unix.pm index a1a91b42607..c150445d776 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Unix.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Unix.pm @@ -3,7 +3,7 @@ package File::Spec::Unix; use strict; use vars qw($VERSION); -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; =head1 NAME @@ -352,11 +352,9 @@ directories. If $path is relative, it is converted to absolute form using L</rel2abs()>. This means that it is taken to be relative to L<cwd()|Cwd>. -No checks against the filesystem are made, so the result may not be correct if -C<$base> contains symbolic links. (Apply -L<Cwd::abs_path()|Cwd/abs_path> beforehand if that -is a concern.) On VMS, there is interaction with the working environment, as -logicals and macros are expanded. +No checks against the filesystem are made. On VMS, there is +interaction with the working environment, as logicals and +macros are expanded. Based on code written by Shigio Yamaguchi. @@ -368,32 +366,28 @@ sub abs2rel { ($path, $base) = map $self->canonpath($_), $path, $base; - my $path_directories; - my $base_directories; - if (grep $self->file_name_is_absolute($_), $path, $base) { ($path, $base) = map $self->rel2abs($_), $path, $base; + } + else { + # save a couple of cwd()s if both paths are relative + ($path, $base) = map $self->catdir('/', $_), $path, $base; + } - my ($path_volume) = $self->splitpath($path, 1); - my ($base_volume) = $self->splitpath($base, 1); + my ($path_volume) = $self->splitpath($path, 1); + my ($base_volume) = $self->splitpath($base, 1); - # Can't relativize across volumes - return $path unless $path_volume eq $base_volume; + # Can't relativize across volumes + return $path unless $path_volume eq $base_volume; - $path_directories = ($self->splitpath($path, 1))[1]; - $base_directories = ($self->splitpath($base, 1))[1]; + my $path_directories = ($self->splitpath($path, 1))[1]; + my $base_directories = ($self->splitpath($base, 1))[1]; - # For UNC paths, the user might give a volume like //foo/bar that - # strictly speaking has no directory portion. Treat it as if it - # had the root directory for that volume. - if (!length($base_directories) and $self->file_name_is_absolute($base)) { - $base_directories = $self->rootdir; - } - } - else { - my $wd= ($self->splitpath($self->_cwd(), 1))[1]; - $path_directories = $self->catdir($wd, $path); - $base_directories = $self->catdir($wd, $base); + # For UNC paths, the user might give a volume like //foo/bar that + # strictly speaking has no directory portion. Treat it as if it + # had the root directory for that volume. + if (!length($base_directories) and $self->file_name_is_absolute($base)) { + $base_directories = $self->rootdir; } # Now, remove all leading components that are the same @@ -401,39 +395,19 @@ sub abs2rel { my @basechunks = $self->splitdir( $base_directories ); if ($base_directories eq $self->rootdir) { - return $self->curdir if $path_directories eq $self->rootdir; shift @pathchunks; return $self->canonpath( $self->catpath('', $self->catdir( @pathchunks ), '') ); } - my @common; while (@pathchunks && @basechunks && $self->_same($pathchunks[0], $basechunks[0])) { - push @common, shift @pathchunks ; + shift @pathchunks ; shift @basechunks ; } return $self->curdir unless @pathchunks || @basechunks; - # @basechunks now contains the directories the resulting relative path - # must ascend out of before it can descend to $path_directory. If there - # are updir components, we must descend into the corresponding directories - # (this only works if they are no symlinks). - my @reverse_base; - while( defined(my $dir= shift @basechunks) ) { - if( $dir ne $self->updir ) { - unshift @reverse_base, $self->updir; - push @common, $dir; - } - elsif( @common ) { - if( @reverse_base && $reverse_base[0] eq $self->updir ) { - shift @reverse_base; - pop @common; - } - else { - unshift @reverse_base, pop @common; - } - } - } - my $result_dirs = $self->catdir( @reverse_base, @pathchunks ); + # $base now contains the directories the resulting relative path + # must ascend out of before it can descend to $path_directory. + my $result_dirs = $self->catdir( ($self->updir) x @basechunks, @pathchunks ); return $self->canonpath( $self->catpath('', $result_dirs, '') ); } @@ -499,8 +473,6 @@ Copyright (c) 2004 by the Perl 5 Porters. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. -Please submit bug reports and patches to perlbug@perl.org. - =head1 SEE ALSO L<File::Spec> diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/VMS.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/VMS.pm index 6af1ac0b3d1..1ababbf1350 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/VMS.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/VMS.pm @@ -4,7 +4,7 @@ use strict; use vars qw(@ISA $VERSION); require File::Spec::Unix; -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; @ISA = qw(File::Spec::Unix); diff --git a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Win32.pm b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Win32.pm index ae74a265931..39f5a8bb95a 100644 --- a/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Win32.pm +++ b/gnu/usr.bin/perl/dist/Cwd/lib/File/Spec/Win32.pm @@ -5,7 +5,7 @@ use strict; use vars qw(@ISA $VERSION); require File::Spec::Unix; -$VERSION = '3.40'; +$VERSION = '3.39_02'; $VERSION =~ tr/_//; @ISA = qw(File::Spec::Unix); diff --git a/gnu/usr.bin/perl/dist/Cwd/t/Spec.t b/gnu/usr.bin/perl/dist/Cwd/t/Spec.t index de6d23792d7..be3139cd1e1 100644 --- a/gnu/usr.bin/perl/dist/Cwd/t/Spec.t +++ b/gnu/usr.bin/perl/dist/Cwd/t/Spec.t @@ -120,10 +120,6 @@ my @tests = ( [ "Unix->abs2rel('/t1/t2/t3', '/t1')", 't2/t3' ], [ "Unix->abs2rel('t1/t2/t3', 't1')", 't2/t3' ], [ "Unix->abs2rel('t1/t2/t3', 't4')", '../t1/t2/t3' ], - [ "Unix->abs2rel('.', '.')", '.' ], - [ "Unix->abs2rel('/', '/')", '.' ], - [ "Unix->abs2rel('../t1', 't2/t3')", '../../../t1' ], - [ "Unix->abs2rel('t1', 't2/../t3')", '../t1' ], [ "Unix->rel2abs('t4','/t1/t2/t3')", '/t1/t2/t3/t4' ], [ "Unix->rel2abs('t4/t5','/t1/t2/t3')", '/t1/t2/t3/t4/t5' ], diff --git a/gnu/usr.bin/perl/dist/Cwd/t/cwd.t b/gnu/usr.bin/perl/dist/Cwd/t/cwd.t index f7b03ed4fc6..c9a218725b9 100644 --- a/gnu/usr.bin/perl/dist/Cwd/t/cwd.t +++ b/gnu/usr.bin/perl/dist/Cwd/t/cwd.t @@ -36,7 +36,7 @@ if ($IsVMS) { $vms_mode = 0 if ($vms_unix_rpt); } -my $tests = 31; +my $tests = 30; # _perl_abs_path() currently only works when the directory separator # is '/', so don't test it when it won't work. my $EXTRA_ABSPATH_TESTS = ($Config{prefix} =~ m/\//) && $^O ne 'cygwin'; @@ -245,16 +245,6 @@ SKIP: { if $EXTRA_ABSPATH_TESTS; } -SKIP: { - my $dir = "${$}a\nx"; - mkdir $dir or skip "OS does not support dir names containing LF"; - chdir $dir or skip "OS cannot chdir into LF"; - eval { Cwd::fast_abs_path() }; - is $@, "", 'fast_abs_path does not die in dir whose name contains LF'; - chdir File::Spec->updir; - rmdir $dir; -} - ############################################# # These routines give us sort of a poor-man's cross-platform diff --git a/gnu/usr.bin/perl/dist/Cwd/t/taint.t b/gnu/usr.bin/perl/dist/Cwd/t/taint.t index 309b3e5dfcb..60cbfebc413 100644 --- a/gnu/usr.bin/perl/dist/Cwd/t/taint.t +++ b/gnu/usr.bin/perl/dist/Cwd/t/taint.t @@ -8,14 +8,7 @@ chdir 't' unless $ENV{PERL_CORE}; use File::Spec; use lib File::Spec->catdir('t', 'lib'); -use Test::More; -BEGIN { - plan( - ${^TAINT} - ? (tests => 17) - : (skip_all => "A perl without taint support") - ); -} +use Test::More tests => 17; use Scalar::Util qw/tainted/; diff --git a/gnu/usr.bin/perl/lib/version/t/01base.t b/gnu/usr.bin/perl/lib/version/t/01base.t index 9aa8052a303..f5784cd568c 100644 --- a/gnu/usr.bin/perl/lib/version/t/01base.t +++ b/gnu/usr.bin/perl/lib/version/t/01base.t @@ -9,7 +9,7 @@ use Test::More qw/no_plan/; BEGIN { (my $coretests = $0) =~ s'[^/]+\.t'coretests.pm'; require $coretests; - use_ok('version', 0.9902); + use_ok('version', 0.97); } diag "Tests with base class" unless $ENV{PERL_CORE}; @@ -32,15 +32,3 @@ my $v = eval { return IO::Handle->VERSION; }; ok defined($v), 'Fix for RT #47980'; - -{ # https://rt.cpan.org/Ticket/Display.html?id=81085 - eval { version::new() }; - like $@, qr'Usage: version::new\(class, version\)', - 'No bus err when called as function'; - eval { $x = 1; print version::new }; - like $@, qr'Usage: version::new\(class, version\)', - 'No implicit object creation when called as function'; - eval { $x = "version"; print version::new }; - like $@, qr'Usage: version::new\(class, version\)', - 'No implicit object creation when called as function'; -} diff --git a/gnu/usr.bin/perl/lib/version/t/02derived.t b/gnu/usr.bin/perl/lib/version/t/02derived.t index c7afe0f9af8..3ea847eb140 100644 --- a/gnu/usr.bin/perl/lib/version/t/02derived.t +++ b/gnu/usr.bin/perl/lib/version/t/02derived.t @@ -10,7 +10,7 @@ use File::Temp qw/tempfile/; BEGIN { (my $coretests = $0) =~ s'[^/]+\.t'coretests.pm'; require $coretests; - use_ok("version", 0.9902); + use_ok("version", 0.97); # If we made it this far, we are ok. } diff --git a/gnu/usr.bin/perl/lib/version/t/03require.t b/gnu/usr.bin/perl/lib/version/t/03require.t index 66c6bd3a85b..90d33ebabeb 100644 --- a/gnu/usr.bin/perl/lib/version/t/03require.t +++ b/gnu/usr.bin/perl/lib/version/t/03require.t @@ -14,7 +14,7 @@ BEGIN { # Don't want to use, because we need to make sure that the import doesn't # fire just yet (some code does this to avoid importing qv() and delare()). require_ok("version"); -is $version::VERSION, 0.9902, "Make sure we have the correct class"; +is $version::VERSION, 0.99, "Make sure we have the correct class"; ok(!"main"->can("qv"), "We don't have the imported qv()"); ok(!"main"->can("declare"), "We don't have the imported declare()"); diff --git a/gnu/usr.bin/perl/lib/version/t/05sigdie.t b/gnu/usr.bin/perl/lib/version/t/05sigdie.t index 188f185587a..2a333392e5e 100644 --- a/gnu/usr.bin/perl/lib/version/t/05sigdie.t +++ b/gnu/usr.bin/perl/lib/version/t/05sigdie.t @@ -15,7 +15,7 @@ BEGIN { BEGIN { - use version 0.9902; + use version 0.97; } pass "Didn't get caught by the wrong DIE handler, which is a good thing"; diff --git a/gnu/usr.bin/perl/lib/version/t/06noop.t b/gnu/usr.bin/perl/lib/version/t/06noop.t index 9d113ed6e41..63f707300b1 100644 --- a/gnu/usr.bin/perl/lib/version/t/06noop.t +++ b/gnu/usr.bin/perl/lib/version/t/06noop.t @@ -7,7 +7,7 @@ use Test::More qw/no_plan/; BEGIN { - use_ok('version', 0.9902); + use_ok('version', 0.97); } my $v1 = version->new('1.2'); diff --git a/gnu/usr.bin/perl/lib/version/t/07locale.t b/gnu/usr.bin/perl/lib/version/t/07locale.t index 3b67f3d77af..506b1bf50f8 100644 --- a/gnu/usr.bin/perl/lib/version/t/07locale.t +++ b/gnu/usr.bin/perl/lib/version/t/07locale.t @@ -8,15 +8,13 @@ use File::Basename; use File::Temp qw/tempfile/; use POSIX qw/locale_h/; use Test::More tests => 7; -use Config; BEGIN { - use_ok('version', 0.9902); + use_ok('version', 0.97); } SKIP: { skip 'No locale testing for Perl < 5.6.0', 6 if $] < 5.006; - skip 'No locale testing without d_setlocale', 6 if(!$Config{d_setlocale}); # test locale handling my $warning; local $SIG{__WARN__} = sub { $warning = $_[0] }; diff --git a/gnu/usr.bin/perl/lib/version/t/coretests.pm b/gnu/usr.bin/perl/lib/version/t/coretests.pm index 15a1f1ff8c9..3f785e47263 100644 --- a/gnu/usr.bin/perl/lib/version/t/coretests.pm +++ b/gnu/usr.bin/perl/lib/version/t/coretests.pm @@ -505,7 +505,6 @@ EOF } { - local $Data::Dumper::Sortkeys= 1; # http://rt.cpan.org/Public/Bug/Display.html?id=30004 my $v1 = $CLASS->$method("v0.1_1"); (my $alpha1 = Dumper($v1)) =~ s/.+'alpha' => ([^,]+),.+/$1/ms; @@ -539,10 +538,9 @@ EOF { # https://rt.cpan.org/Ticket/Display.html?id=72365 # https://rt.perl.org/rt3/Ticket/Display.html?id=102586 - # https://rt.cpan.org/Ticket/Display.html?id=78328 eval 'my $v = $CLASS->$method("version")'; like $@, qr/Invalid version format/, - "The string 'version' is not a version for $method"; + 'The string "version" is not a version'; eval 'my $v = $CLASS->$method("ver510n")'; like $@, qr/Invalid version format/, 'All strings starting with "v" are not versions'; @@ -595,14 +593,6 @@ SKIP: { eval { _112478->VERSION(9e99) }; unlike $@, qr/panic/, '->VERSION(9e99) does not panic'; } - - { # https://rt.cpan.org/Ticket/Display.html?id=79259 - my $v = $CLASS->new("0.52_0"); - ok $v->is_alpha, 'Just checking'; - is $v->numify, '0.520', 'Correctly nummified'; - } - } 1; - diff --git a/gnu/usr.bin/perl/t/porting/customized.dat b/gnu/usr.bin/perl/t/porting/customized.dat index bdb8eb21306..f9620442ee4 100644 --- a/gnu/usr.bin/perl/t/porting/customized.dat +++ b/gnu/usr.bin/perl/t/porting/customized.dat @@ -1,16 +1,13 @@ -Text::Balanced cpan/Text-Balanced/t/01_compile.t 1598cf491a48fa546260a2ec41142abe84da533d -Text::Balanced cpan/Text-Balanced/t/02_extbrk.t 6ba1b64a4604e822dc2260b8ffcea6b406339ee8 -Text::Balanced cpan/Text-Balanced/t/03_extcbk.t 3307c980af28963414cab799c427b359ef3b8657 -Text::Balanced cpan/Text-Balanced/t/04_extdel.t be993c5c295b125b4be0ed55f866a249599f5835 -Text::Balanced cpan/Text-Balanced/t/05_extmul.t 4d1bc60add35ac203873f5371d8c6fcc9c8b6d80 -Text::Balanced cpan/Text-Balanced/t/06_extqlk.t 81a5804d392013393a338325b197cea52c4c44e0 -Text::Balanced cpan/Text-Balanced/t/07_exttag.t 5a209ed156387d4614d3003292e5fc412b8541e5 -Text::Balanced cpan/Text-Balanced/t/08_extvar.t 0776ef2cbdad5b1fbefb300541d079212cc24d92 -Text::Balanced cpan/Text-Balanced/t/09_gentag.t 42361b5dfb3bb728bce20f4fb0d92ccfb27c2ba7 Module::Build cpan/Module-Build/lib/Module/Build/ConfigData.pm 2f3f07fd889077ebd51791ad6e195d9164b4baf3 -Test::Harness cpan/Test-Harness/t/source.t 884890970fb850874213159df263ba483bac62e9 -CPANPLUS cpan/CPANPLUS/Makefile.PL 5d533f6722af6aae73204755beb8d6c008fc0d4a -libnet cpan/libnet/Makefile.PL 5554b71464b45f5cc002e55f2464f7ff4abd05b6 -podlators cpan/podlators/scripts/pod2man.PL f81acf53f3ff46cdcc5ebdd661c5d13eb35d20d6 -podlators cpan/podlators/scripts/pod2text.PL b4693fcfe4a0a1b38a215cfb8985a65d5d025d69 +Test::Harness cpan/Test-Harness/t/source.t 61738913dac9ba6c4504756d355c23c25c47d31e +Test::Harness cpan/Test-Harness/t/testargs.t 79c91b2ea73f7cbfb9bae45dec4a62db74cb8dbf Module::Pluggable cpan/Module-Pluggable/Makefile.PL 72062c1a01ed7c62d16c55122c163b2d89f0d739 +autodie cpan/autodie/t/open.t cb493da4305f591ca0344d09e8a840a3147c5579 +libnet cpan/libnet/Makefile.PL 5554b71464b45f5cc002e55f2464f7ff4abd05b6 +podlators cpan/podlators/scripts/pod2man.PL 8fb484dc560adb00889f504760ca0a4defa9dc40 +podlators cpan/podlators/scripts/pod2text.PL 53ccba9264368c3f9acd2a36d1d354797d2a88f6 +podlators pod/perlpodstyle.pod 4f1ba65eddc5576267954b948556e16a9686c411 +CPANPLUS cpan/CPANPLUS/Makefile.PL 5d533f6722af6aae73204755beb8d6c008fc0d4a +Text-Tabs+Wrap cpan/Text-Tabs/t/fill.t a960d2c4f66b7e30557b5479e0da2da1bf7a7f45 +Text-Tabs+Wrap cpan/Text-Tabs/t/tabs.t 63a67b3a319c858d7e66306b8a653de1951153dc +Sys::Syslog cpan/Sys-Syslog/t/syslog.t 647571fc90918883b871ff7e005ed7ab8a223784 |