Hello community,
here is the log from the commit of package perl-autodie for openSUSE:Factory checked in at 2014-03-09 18:33:47
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-autodie (Old)
and /work/SRC/openSUSE:Factory/.perl-autodie.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-autodie"
Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-autodie/perl-autodie.changes 2013-10-06 14:53:01.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-autodie.new/perl-autodie.changes 2014-03-09 18:33:48.000000000 +0100
@@ -1,0 +2,23 @@
+Fri Mar 7 06:53:34 UTC 2014 - coolo@suse.com
+
+- updated to 2.23
+ * TEST / BUGFIX: Improved testing support on Android
+ and Blackberry devices. (GH #44, thanks to
+ Hugmeir.)
+
+ * TEST / INTERNAL / TRAVIS: Various non-code
+ tweaks to make travis-ci more happy with testing
+ autodie.
+
+ * BUGFIX: autodie no longer weakens strict by allowing
+ undeclared variables with the same name as built-ins.
+ (RT #74246, thanks to Neils Thykier and Father
+ Chrysostomos.)
+
+ * BUGFIX: `use autodie qw( foo ! foo);` now correctly
+ insists that we have hints for foo. (Thanks Niels Thykier)
+
+ * INTERNAL: Improved benchmarking code, thanks to
+ Niels Thykier.
+
+-------------------------------------------------------------------
Old:
----
autodie-2.22.tar.gz
New:
----
autodie-2.23.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-autodie.spec ++++++
--- /var/tmp/diff_new_pack.ovHxuK/_old 2014-03-09 18:33:49.000000000 +0100
+++ /var/tmp/diff_new_pack.ovHxuK/_new 2014-03-09 18:33:49.000000000 +0100
@@ -1,7 +1,7 @@
#
# spec file for package perl-autodie
#
-# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
Name: perl-autodie
-Version: 2.22
+Version: 2.23
Release: 0
%define cpan_name autodie
Summary: Replace functions with ones that succeed or die with lexical scope
@@ -29,33 +29,6 @@
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: perl
BuildRequires: perl-macros
-#BuildRequires: perl(autodie)
-#BuildRequires: perl(autodie::exception)
-#BuildRequires: perl(autodie::exception::system)
-#BuildRequires: perl(autodie::hints)
-#BuildRequires: perl(autodie::skip)
-#BuildRequires: perl(autodie_skippy)
-#BuildRequires: perl(autodie::test::au)
-#BuildRequires: perl(autodie::test::au::exception)
-#BuildRequires: perl(autodie::test::badname)
-#BuildRequires: perl(autodie::test::missing)
-#BuildRequires: perl(autodie_test_module)
-#BuildRequires: perl(BSD::Resource)
-#BuildRequires: perl(Caller_helper)
-#BuildRequires: perl(Fatal_Leaky_Benchmark)
-#BuildRequires: perl(Hints_pod_examples)
-#BuildRequires: perl(Hints_provider_does)
-#BuildRequires: perl(Hints_provider_easy_does_it)
-#BuildRequires: perl(Hints_provider_isa)
-#BuildRequires: perl(Hints_test)
-#BuildRequires: perl(IPC::System::Simple)
-#BuildRequires: perl(lethal)
-#BuildRequires: perl(my::autodie)
-#BuildRequires: perl(pujHa'ghach)
-#BuildRequires: perl(Some::Module)
-#BuildRequires: perl(Sub::Identify)
-#BuildRequires: perl(Test::Kwalitee)
-#BuildRequires: perl(Test::Perl::Critic)
Recommends: perl(IPC::System::Simple) >= 0.12
Recommends: perl(Sub::Identify)
%{perl_requires}
@@ -97,6 +70,6 @@
%files -f %{name}.files
%defattr(-,root,root,755)
-%doc AUTHORS benchmarks Changes LICENSE README
+%doc AUTHORS Changes LICENSE README
%changelog
++++++ autodie-2.22.tar.gz -> autodie-2.23.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/Changes new/autodie-2.23/Changes
--- old/autodie-2.22/Changes 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/Changes 2014-01-27 03:51:03.000000000 +0100
@@ -1,5 +1,26 @@
Revision history for autodie
+2.23 2014-01-27 13:50:55EST+1100 Australia/Melbourne
+
+ * TEST / BUGFIX: Improved testing support on Android
+ and Blackberry devices. (GH #44, thanks to
+ Hugmeir.)
+
+ * TEST / INTERNAL / TRAVIS: Various non-code
+ tweaks to make travis-ci more happy with testing
+ autodie.
+
+ * BUGFIX: autodie no longer weakens strict by allowing
+ undeclared variables with the same name as built-ins.
+ (RT #74246, thanks to Neils Thykier and Father
+ Chrysostomos.)
+
+ * BUGFIX: `use autodie qw( foo ! foo);` now correctly
+ insists that we have hints for foo. (Thanks Niels Thykier)
+
+ * INTERNAL: Improved benchmarking code, thanks to
+ Niels Thykier.
+
2.22 2013-09-21 11:37:14 Asia/Tokyo
* TEST / INTERNAL: Restore timestamps on touched testing
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/LICENSE new/autodie-2.23/LICENSE
--- old/autodie-2.22/LICENSE 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/LICENSE 2014-01-27 03:51:03.000000000 +0100
@@ -1,4 +1,4 @@
-This software is copyright (c) 2013 by Paul Fenwick and others (see AUTHORS file).
+This software is copyright (c) 2014 by Paul Fenwick and others (see AUTHORS file).
This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.
@@ -12,7 +12,7 @@
--- The GNU General Public License, Version 1, February 1989 ---
-This software is Copyright (c) 2013 by Paul Fenwick and others (see AUTHORS file).
+This software is Copyright (c) 2014 by Paul Fenwick and others (see AUTHORS file).
This is free software, licensed under:
@@ -272,7 +272,7 @@
--- The Artistic License 1.0 ---
-This software is Copyright (c) 2013 by Paul Fenwick and others (see AUTHORS file).
+This software is Copyright (c) 2014 by Paul Fenwick and others (see AUTHORS file).
This is free software, licensed under:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/MANIFEST new/autodie-2.23/MANIFEST
--- old/autodie-2.22/MANIFEST 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/MANIFEST 2014-01-27 03:51:03.000000000 +0100
@@ -1,3 +1,4 @@
+# This file was automatically generated by Dist::Zilla::Plugin::Manifest v5.012.
AUTHORS
Changes
LICENSE
@@ -11,6 +12,7 @@
benchmarks/benchmark.pl
benchmarks/call.pl
benchmarks/leak.pl
+benchmarks/raw-call.pl
dist.ini
lib/Fatal.pm
lib/autodie.pm
@@ -20,6 +22,7 @@
lib/autodie/skip.pm
t/00-load.t
t/Fatal.t
+t/args.t
t/author-critic.t
t/autodie.t
t/autodie_skippy.pm
@@ -84,6 +87,7 @@
t/release-pod-coverage.t
t/release-pod-syntax.t
t/repeat.t
+t/rt-74246.t
t/scope_leak.t
t/skip.t
t/socket.t
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/META.json new/autodie-2.23/META.json
--- old/autodie-2.22/META.json 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/META.json 2014-01-27 03:51:03.000000000 +0100
@@ -4,7 +4,7 @@
"Paul Fenwick "
],
"dynamic_config" : 0,
- "generated_by" : "Dist::Zilla version 4.300034, CPAN::Meta::Converter version 2.120921",
+ "generated_by" : "Dist::Zilla version 5.012, CPAN::Meta::Converter version 2.120921",
"license" : [
"perl_5"
],
@@ -35,7 +35,6 @@
"requires" : {
"B" : "0",
"Carp" : "0",
- "Config" : "0",
"Exporter" : "0",
"Fcntl" : "0",
"POSIX" : "0",
@@ -53,6 +52,7 @@
"test" : {
"recommends" : {
"BSD::Resource" : "0",
+ "Pod::Coverage::TrustPod" : "0",
"Test::Kwalitee" : "0",
"Test::Perl::Critic" : "0",
"perl" : "5.010"
@@ -65,6 +65,7 @@
"IO::Handle" : "0",
"Socket" : "0",
"Test::More" : "0",
+ "lib" : "0",
"open" : "0"
}
}
@@ -80,6 +81,6 @@
"web" : "https://github.com/pjf/autodie"
}
},
- "version" : "2.22"
+ "version" : "2.23"
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/META.yml new/autodie-2.23/META.yml
--- old/autodie-2.22/META.yml 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/META.yml 2014-01-27 03:51:03.000000000 +0100
@@ -10,11 +10,12 @@
IO::Handle: 0
Socket: 0
Test::More: 0
+ lib: 0
open: 0
configure_requires:
ExtUtils::MakeMaker: 6.30
dynamic_config: 0
-generated_by: 'Dist::Zilla version 4.300034, CPAN::Meta::Converter version 2.120921'
+generated_by: 'Dist::Zilla version 5.012, CPAN::Meta::Converter version 2.120921'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -27,7 +28,6 @@
requires:
B: 0
Carp: 0
- Config: 0
Exporter: 0
Fcntl: 0
POSIX: 0
@@ -43,4 +43,4 @@
resources:
bugtracker: http://rt.cpan.org/NoAuth/Bugs.html?Dist=autodie
repository: git://github.com/pjf/autodie
-version: 2.22
+version: 2.23
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/Makefile.PL new/autodie-2.23/Makefile.PL
--- old/autodie-2.22/Makefile.PL 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/Makefile.PL 2014-01-27 03:51:03.000000000 +0100
@@ -1,4 +1,5 @@
+# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v5.012.
use strict;
use warnings;
@@ -22,7 +23,6 @@
"PREREQ_PM" => {
"B" => 0,
"Carp" => 0,
- "Config" => 0,
"Exporter" => 0,
"Fcntl" => 0,
"POSIX" => 0,
@@ -43,39 +43,46 @@
"IO::Handle" => 0,
"Socket" => 0,
"Test::More" => 0,
+ "lib" => 0,
"open" => 0
},
- "VERSION" => "2.22",
+ "VERSION" => "2.23",
"test" => {
"TESTS" => "t/*.t"
}
);
-unless ( eval { ExtUtils::MakeMaker->VERSION(6.63_03) } ) {
- my $tr = delete $WriteMakefileArgs{TEST_REQUIRES};
- my $br = $WriteMakefileArgs{BUILD_REQUIRES};
- for my $mod ( keys %$tr ) {
- if ( exists $br->{$mod} ) {
- $br->{$mod} = $tr->{$mod} if $tr->{$mod} > $br->{$mod};
- }
- else {
- $br->{$mod} = $tr->{$mod};
- }
- }
-}
+my %FallbackPrereqs = (
+ "B" => 0,
+ "Carp" => 0,
+ "Exporter" => 0,
+ "Fcntl" => 0,
+ "File::Copy" => 0,
+ "File::Spec" => 0,
+ "File::Temp" => 0,
+ "FindBin" => 0,
+ "IO::Handle" => 0,
+ "POSIX" => 0,
+ "Scalar::Util" => 0,
+ "Socket" => 0,
+ "Test::More" => 0,
+ "Tie::RefHash" => 0,
+ "base" => 0,
+ "constant" => 0,
+ "if" => 0,
+ "lib" => 0,
+ "open" => 0,
+ "overload" => 0,
+ "strict" => 0,
+ "warnings" => 0
+);
-unless ( eval { ExtUtils::MakeMaker->VERSION(6.56) } ) {
- my $br = delete $WriteMakefileArgs{BUILD_REQUIRES};
- my $pp = $WriteMakefileArgs{PREREQ_PM};
- for my $mod ( keys %$br ) {
- if ( exists $pp->{$mod} ) {
- $pp->{$mod} = $br->{$mod} if $br->{$mod} > $pp->{$mod};
- }
- else {
- $pp->{$mod} = $br->{$mod};
- }
- }
+
+unless ( eval { ExtUtils::MakeMaker->VERSION(6.63_03) } ) {
+ delete $WriteMakefileArgs{TEST_REQUIRES};
+ delete $WriteMakefileArgs{BUILD_REQUIRES};
+ $WriteMakefileArgs{PREREQ_PM} = \%FallbackPrereqs;
}
delete $WriteMakefileArgs{CONFIGURE_REQUIRES}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/benchmarks/Fatal_Leaky_Benchmark.pm new/autodie-2.23/benchmarks/Fatal_Leaky_Benchmark.pm
--- old/autodie-2.22/benchmarks/Fatal_Leaky_Benchmark.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/benchmarks/Fatal_Leaky_Benchmark.pm 2014-01-27 03:51:03.000000000 +0100
@@ -5,14 +5,14 @@
# And *don't* use a package.
# Either of those will stop autodie leaking into this file.
-use constant N => 1000;
+use constant N => 1000000;
# Essentially run a no-op many times. With a high leak overhead,
# this is expensive. With a low leak overhead, this should be cheap.
sub run {
for (1..N) {
- close(NOFILE);
+ binmode(STDOUT);
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/benchmarks/call.pl new/autodie-2.23/benchmarks/call.pl
--- old/autodie-2.22/benchmarks/call.pl 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/benchmarks/call.pl 2014-01-27 03:51:03.000000000 +0100
@@ -8,7 +8,9 @@
# Run an autodie wrapped sub many times in what's essentially a no-op.
# This should give us an idea of autodie's overhead.
-
-for (1..N) {
- binmode(STDOUT);
+sub run {
+ for (1..N) {
+ binmode(STDOUT);
+ }
}
+run();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/benchmarks/raw-call.pl new/autodie-2.23/benchmarks/raw-call.pl
--- old/autodie-2.22/benchmarks/raw-call.pl 1970-01-01 01:00:00.000000000 +0100
+++ new/autodie-2.23/benchmarks/raw-call.pl 2014-01-27 03:51:03.000000000 +0100
@@ -0,0 +1,17 @@
+#!/usr/bin/perl -w
+use 5.010;
+use strict;
+use warnings;
+
+use constant N => 1000000;
+
+# Essentially run a no-op many times - This is useful for comparison
+# with leak.pl or call.pl
+
+
+sub run {
+ for (1..N) {
+ binmode(STDOUT);
+ }
+}
+run();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/dist.ini new/autodie-2.23/dist.ini
--- old/autodie-2.22/dist.ini 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/dist.ini 2014-01-27 03:51:03.000000000 +0100
@@ -58,6 +58,9 @@
Test::Kwalitee = 0
Test::Perl::Critic = 0
+; release-pod-coverage.t likes this
+Pod::Coverage::TrustPod = 0;
+
[Prereqs / RuntimeRecommends]
perl = 5.010
IPC::System::Simple = 0.12
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/lib/Fatal.pm new/autodie-2.23/lib/Fatal.pm
--- old/autodie-2.22/lib/Fatal.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/lib/Fatal.pm 2014-01-27 03:51:03.000000000 +0100
@@ -48,7 +48,7 @@
use constant MIN_IPC_SYS_SIMPLE_VER => 0.12;
-our $VERSION = '2.22'; # VERSION: Generated by DZP::OurPkg::Version
+our $VERSION = '2.23'; # VERSION: Generated by DZP::OurPkg::Version
our $Debug ||= 0;
@@ -144,6 +144,7 @@
':2.20' => [qw(:default)],
':2.21' => [qw(:default)],
':2.22' => [qw(:default)],
+ ':2.23' => [qw(:default)],
);
# chmod was only introduced in 2.07
@@ -378,15 +379,16 @@
# pass-through unknown tags (i.e. we have to manually handle
# VOID_TAG).
#
- # TODO: Consider how to handle stuff like:
- # use autodie qw(:defaults ! :io);
- # use Fatal qw(:defaults :void :io);
+ # NB: _translate_import_args re-orders everything for us, so
+ # we don't have to worry about stuff like:
#
- # The ! and :void is currently not applied to anything in the
- # example above since duplicates are filtered out. This has been
- # autodie's behaviour for quite a while, but it might make sense
- # to change it so "!" or ":void" applies to stuff after they
- # appear (even if they are all duplicates).
+ # :default :void :io
+ #
+ # That will (correctly) translated into
+ #
+ # expand(:defaults-without-io) :void :io
+ #
+ # by _translate_import_args.
for my $func ($class->_translate_import_args(@fatalise_these)) {
if ($func eq VOID_TAG) {
@@ -503,18 +505,26 @@
# It does not hurt to do this in a predictable order, and might help debugging.
foreach my $sub_name (sort keys %$subs_to_reinstate) {
- my $sub_ref= $subs_to_reinstate->{$sub_name};
- my $full_path = $pkg_sym.$sub_name;
-
- # Copy symbols across to temp area.
+ # We will repeatedly mess with stuff that strict "refs" does
+ # not like. So lets just disable it once for this entire
+ # scope.
+ no strict qw(refs); ## no critic
- no strict 'refs'; ## no critic
+ my $sub_ref= $subs_to_reinstate->{$sub_name};
- local *__tmp = *{ $full_path };
+ my $full_path = $pkg_sym.$sub_name;
+ my $oldglob = *$full_path;
# Nuke the old glob.
- { no strict; delete $pkg_sym->{$sub_name}; } ## no critic
+ delete $pkg_sym->{$sub_name};
+
+ # For some reason this local *alias = *$full_path triggers an
+ # "only used once" warning. Not entirely sure why, but at
+ # least it is easy to silence.
+ no warnings qw(once);
+ local *alias = *$full_path;
+ use warnings qw(once);
# Copy innocent bystanders back. Note that we lose
# formats; it seems that Perl versions up to 5.10.0
@@ -522,16 +532,12 @@
# the scalar slot. Thanks to Ben Morrow for spotting this.
foreach my $slot (qw( SCALAR ARRAY HASH IO ) ) {
- next unless defined *__tmp{ $slot };
- *{ $full_path } = *__tmp{ $slot };
+ next unless defined *$oldglob{$slot};
+ *alias = *$oldglob{$slot};
}
- # Put back the old sub (if there was one).
-
if ($sub_ref) {
-
- no strict; ## no critic
- *{ $full_path } = $sub_ref;
+ *$full_path = $sub_ref;
}
}
@@ -597,31 +603,83 @@
sub _translate_import_args {
my ($class, @args) = @_;
my @result;
- for my $a (@args){
+ my %seen;
+
+ if (@args < 2) {
+ # Optimize for this case, as it is fairly common. (e.g. use
+ # autodie; or use autodie qw(:all); both trigger this).
+ return unless @args;
+
+ # Not a (known) tag, pass through.
+ return @args unless exists($TAGS{$args[0]});
+
+ # Strip "CORE::" from all elements in the list as import and
+ # unimport does not handle the "CORE::" prefix too well.
+ #
+ # NB: we use substr as it is faster than s/^CORE::// and
+ # it does not change the elements.
+ return map { substr($_, 6) } @{ $class->_expand_tag($args[0]) };
+ }
+
+ # We want to translate
+ #
+ # :default :void :io
+ #
+ # into (pseudo-ish):
+ #
+ # expanded(:threads) :void expanded(:io)
+ #
+ # We accomplish this by "reverse, expand + filter, reverse".
+ for my $a (reverse(@args)) {
if (exists $TAGS{$a}) {
my $expanded = $class->_expand_tag($a);
- # Strip "CORE::" from all elements in the list as import and
- # unimport does not handle the "CORE::" prefix too well.
- #
- # NB: we use substr as it is faster than s/^CORE::// and
- # it does not change the elements.
- push @result, map { substr($_, 6) } @{$expanded};
+ push(@result,
+ # Remove duplicates after ...
+ grep { !$seen{$_}++ }
+ # we have stripped CORE:: (see above)
+ map { substr($_, 6) }
+ # We take the elements in reverse order
+ # (as @result be reversed later).
+ reverse(@{$expanded}));
} else {
- #pass through
+ # pass through - no filtering here for tags.
+ #
+ # The reason for not filtering tags cases like:
+ #
+ # ":default :void :io :void :threads"
+ #
+ # As we have reversed args, we see this as:
+ #
+ # ":threads :void :io :void* :default*"
+ #
+ # (Entries marked with "*" will be filtered out completely). When
+ # reversed again, this will be:
+ #
+ # ":io :void :threads"
+ #
+ # But we would rather want it to be:
+ #
+ # ":void :io :threads" or ":void :io :void :threads"
+ #
+
+ my $letter = substr($a, 0, 1);
+ if ($letter ne ':' && $a ne INSIST_TAG) {
+ next if $seen{$a}++;
+ if ($letter eq '!' and $seen{substr($a, 1)}++) {
+ my $name = substr($a, 1);
+ # People are being silly and doing:
+ #
+ # use autodie qw(!a a);
+ #
+ # Enjoy this little O(n) clean up...
+ @result = grep { $_ ne $name } @result;
+ }
+ }
push @result, $a;
}
}
- # If @args < 2, then we have no duplicates (because _expand_tag
- # does not have duplicates and if it is not a tag, it is just a
- # single value). We optimize for this because it is a fairly
- # common case (e.g. use autodie; or use autodie qw(:all); both
- # trigger this).
- return @result if @args < 2;
-
- my %seen = ();
- # Yes, this is basically List::MoreUtils's uniq/distinct, but
- # List::MoreUtils is not in the Perl core and autodie is
- return grep { !$seen{$_}++ } @result;
+ # Reverse the result to restore the input order
+ return reverse(@result);
}
@@ -1849,6 +1907,6 @@
LIPC::System::Simple for a similar idea for calls to C
and backticks.
-=for Pod::Coverage exception_class fill_protos one_invocation throw write_invocation
+=for Pod::Coverage exception_class fill_protos one_invocation throw write_invocation ERROR_NO_IPC_SYS_SIMPLE LEXICAL_TAG
=cut
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/lib/autodie/exception/system.pm new/autodie-2.23/lib/autodie/exception/system.pm
--- old/autodie-2.22/lib/autodie/exception/system.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/lib/autodie/exception/system.pm 2014-01-27 03:51:03.000000000 +0100
@@ -5,7 +5,7 @@
use base 'autodie::exception';
use Carp qw(croak);
-our $VERSION = '2.22'; # VERSION: Generated by DZP::OurPkg:Version
+our $VERSION = '2.23'; # VERSION: Generated by DZP::OurPkg:Version
# ABSTRACT: Exceptions from autodying system().
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/lib/autodie/exception.pm new/autodie-2.23/lib/autodie/exception.pm
--- old/autodie-2.22/lib/autodie/exception.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/lib/autodie/exception.pm 2014-01-27 03:51:03.000000000 +0100
@@ -4,7 +4,7 @@
use warnings;
use Carp qw(croak);
-our $VERSION = '2.22'; # VERSION: Generated by DZP::OurPkg:Version
+our $VERSION = '2.23'; # VERSION: Generated by DZP::OurPkg:Version
# ABSTRACT: Exceptions from autodying functions.
our $DEBUG = 0;
@@ -404,6 +404,8 @@
elsif ($mode eq '>') { $wordy_mode = 'writing'; }
elsif ($mode eq '>>') { $wordy_mode = 'appending'; }
+ $file = '<undef>' if not defined $file;
+
return sprintf _FORMAT_OPEN, $file, $wordy_mode, $error if $wordy_mode;
Carp::confess("Internal autodie::exception error: Don't know how to format mode '$mode'.");
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/lib/autodie/hints.pm new/autodie-2.23/lib/autodie/hints.pm
--- old/autodie-2.22/lib/autodie/hints.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/lib/autodie/hints.pm 2014-01-27 03:51:03.000000000 +0100
@@ -5,7 +5,7 @@
use constant PERL58 => ( $] < 5.009 );
-our $VERSION = '2.22'; # VERSION: Generated by DZP::OurPkg:Version
+our $VERSION = '2.23'; # VERSION: Generated by DZP::OurPkg:Version
# ABSTRACT: Provide hints about user subroutines to autodie
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/lib/autodie/skip.pm new/autodie-2.23/lib/autodie/skip.pm
--- old/autodie-2.22/lib/autodie/skip.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/lib/autodie/skip.pm 2014-01-27 03:51:03.000000000 +0100
@@ -2,7 +2,7 @@
use strict;
use warnings;
-our $VERSION = '2.22'; # VERSION
+our $VERSION = '2.23'; # VERSION
# This package exists purely so people can inherit from it,
# which isn't at all how roles are supposed to work, but it's
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/lib/autodie.pm new/autodie-2.23/lib/autodie.pm
--- old/autodie-2.22/lib/autodie.pm 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/lib/autodie.pm 2014-01-27 03:51:03.000000000 +0100
@@ -10,7 +10,7 @@
# ABSTRACT: Replace functions with ones that succeed or die with lexical scope
BEGIN {
- our $VERSION = '2.22'; # VERSION: Generated by DZP::OurPkg::Version
+ our $VERSION = '2.23'; # VERSION: Generated by DZP::OurPkg::Version
}
use constant ERROR_WRONG_FATAL => q{
@@ -265,6 +265,10 @@
=head1 FUNCTION SPECIFIC NOTES
+=head2 print
+
+The autodie pragma B<>.
+
=head2 flock
It is not considered an error for C<flock> to return false if it fails
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/t/Fatal.t new/autodie-2.23/t/Fatal.t
--- old/autodie-2.22/t/Fatal.t 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/t/Fatal.t 2014-01-27 03:51:03.000000000 +0100
@@ -5,7 +5,7 @@
use Test::More tests => 17;
-use Fatal qw(open close :void opendir);
+use Fatal qw(:io :void opendir);
eval { open FOO, "<".NO_SUCH_FILE }; # Two arg open
like($@, qr/^Can't open/, q{Package Fatal::open});
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/t/args.t new/autodie-2.23/t/args.t
--- old/autodie-2.22/t/args.t 1970-01-01 01:00:00.000000000 +0100
+++ new/autodie-2.23/t/args.t 2014-01-27 03:51:03.000000000 +0100
@@ -0,0 +1,46 @@
+#!/usr/bin/perl -w
+use strict;
+use warnings;
+
+use Test::More tests => 7;
+
+require Fatal;
+
+my @default = expand(':default');
+my @threads = expand(':threads');
+my @io = expand(':io');
+my %io_hash = map { $_ => 1 } @io;
+my @default_minus_io = grep { !exists($io_hash{$_}) } @default;
+
+is_deeply(translate('!a', 'a'), ['!a'], 'Keeps insist variant');
+
+is_deeply(translate(':default'), \@default,
+ 'translate and expand agrees');
+
+is_deeply(translate(':default', ':void', ':io'),
+ [@default_minus_io, ':void', @io],
+ ':void position is respected');
+
+is_deeply(translate(':default', ':void', ':io', ':void', ':threads'),
+ [':void', @io, ':void', @threads],
+ ':void (twice) position are respected');
+
+is_deeply(translate(':default', '!', ':io'),
+ [@default_minus_io, '!', @io], '! position is respected');
+
+is_deeply(translate(':default', '!', ':io', '!', ':threads'),
+ ['!', @io, '!', @threads],
+ '! (twice) positions are respected');
+
+is_deeply(translate(':default', '!open', '!', ':io'),
+ [@default_minus_io, '!open', '!', grep { $_ ne 'open' } @io],
+ '!open ! :io works as well');
+
+sub expand {
+ # substr is to strip "CORE::" without modifying $_
+ return map { substr($_, 6) } @{Fatal->_expand_tag(@_)};
+}
+
+sub translate {
+ return [Fatal->_translate_import_args(@_)];
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/t/open.t new/autodie-2.23/t/open.t
--- old/autodie-2.22/t/open.t 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/t/open.t 2014-01-27 03:51:03.000000000 +0100
@@ -53,12 +53,18 @@
# Sniff to see if we can run 'true' on this system. Changes we can't
# on non-Unix systems.
+use Config;
+my @true = ($^O =~ /android/
+ || ($Config{usecrosscompile} && $^O eq 'nto' ))
+ ? ('sh', '-c', 'true $@', '--')
+ : 'true';
+
eval {
use autodie;
die "Windows and VMS do not support multi-arg pipe" if $^O eq "MSWin32" or $^O eq 'VMS';
- open(my $fh, '-|', "true");
+ open(my $fh, '-|', @true);
};
SKIP: {
@@ -68,10 +74,10 @@
use autodie;
my $fh;
- open $fh, "-|", "true";
- open $fh, "-|", "true", "foo";
- open $fh, "-|", "true", "foo", "bar";
- open $fh, "-|", "true", "foo", "bar", "baz";
+ open $fh, "-|", @true;
+ open $fh, "-|", @true, "foo";
+ open $fh, "-|", @true, "foo", "bar";
+ open $fh, "-|", @true, "foo", "bar", "baz";
};
is $@, '', "multi arg piped open does not fail";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/t/release-pod-coverage.t new/autodie-2.23/t/release-pod-coverage.t
--- old/autodie-2.22/t/release-pod-coverage.t 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/t/release-pod-coverage.t 2014-01-27 03:51:03.000000000 +0100
@@ -7,6 +7,7 @@
}
}
+# This file was automatically generated by Dist::Zilla::Plugin::PodCoverageTests.
use Test::More;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/t/release-pod-syntax.t new/autodie-2.23/t/release-pod-syntax.t
--- old/autodie-2.22/t/release-pod-syntax.t 2013-09-21 04:37:23.000000000 +0200
+++ new/autodie-2.23/t/release-pod-syntax.t 2014-01-27 03:51:03.000000000 +0100
@@ -7,6 +7,7 @@
}
}
+# This file was automatically generated by Dist::Zilla::Plugin::PodSyntaxTests.
use Test::More;
eval "use Test::Pod 1.41";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/autodie-2.22/t/rt-74246.t new/autodie-2.23/t/rt-74246.t
--- old/autodie-2.22/t/rt-74246.t 1970-01-01 01:00:00.000000000 +0100
+++ new/autodie-2.23/t/rt-74246.t 2014-01-27 03:51:03.000000000 +0100
@@ -0,0 +1,14 @@
+#!/usr/bin/perl -w
+
+use strict;
+
+use Test::More tests => 1;
+
+eval q{
+ use strict;
+ no warnings; # Suppress a "helpful" warning on STDERR
+ use autodie qw(open);
+ $open = 1;
+};
+like($@, qr/Global symbol "\$open" requires explicit package name/,
+ 'autodie does not break "use strict;"');
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org