This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Added a failing test for a bareword parsing regression created in 984f9f66
authorSlaven Rezic <slaven@rezic.de>
Tue, 11 Aug 2009 21:20:05 +0000 (23:20 +0200)
committerJesse Vincent <jesse@bestpractical.com>
Wed, 12 Aug 2009 23:32:29 +0000 (19:32 -0400)
Date: Tue, 11 Aug 2009 23:20:05 +0200
From: Slaven Rezic <slaven@rezic.de>
To: perl5-porters@perl.org
Subject: Re: 5.10.1: regression regarding bareword in readline()
Reply-to: slaven@rezic.de

On Tue 11.Aug'09 at 23:20:05 +0200, Slaven Rezic wrote:
> > git bisect says that the breakage occurred in
> > 109c3d50375e96ee005ac98a3d457c7da2f5cb08 in the maint-5.10 branch,
> > respective in 984f9f66477bc722578262ae8520584e44e881af in the blead branch.
> >
> > This breaks at least the CPAN distribution MySQL-Backup-0.04.
> >
> > /usr/perl-5.10.0-3220-gf9961a0/bin/perl -c -e 'use strict; readline(STDIN)'
> I found another CPAN distribution with the same problem: Tie-Simple-1.03
>
> And there's another bareword problem, found in Games-Go-GoPair-1.001.>     use strict;
>     my @players;
>     sub _rankCompare { }
>     @players = sort(_rankCompare @players);

t/lib/strict/subs

index c18af68..e8e1324 100644 (file)
@@ -408,3 +408,17 @@ system(FOO . "\n");
 EXPECT
 Bareword "FOO" not allowed while "strict subs" in use at - line 4.
 Execution of - aborted due to compilation errors.
+########
+# commit 984f9f66477bc722578262ae8520584e44e881af broke this parsing
+use strict 'subs';
+my @players;
+sub _rankCompare { }
+@players = sort(_rankCompare @players);
+EXPECT
+
+########
+# commit 984f9f66477bc722578262ae8520584e44e881af broke this parsing
+use strict;
+readline(STDIN);
+EXPECT
+