Skip Menu |

This queue is for tickets about the Parse-Yapp CPAN distribution.

Report information
The Basics
Id: 106685
Status: resolved
Worked: 10 hours (600 min)
Priority: 0/
Queue: Parse-Yapp

People
Owner: Nobody in particular
Requestors: rklement [...] pacbell.net
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: 1.2



Subject: yapp outputs two "deprecated" warnings on perl v5.22.0
Date: Wed, 26 Aug 2015 18:15:38 -0700
To: bug-Parse-Yapp [...] rt.cpan.org
From: Rick Klement <rklement [...] pacbell.net>
Perl v5.22.0 has deprecated using unescaped { in a regex. yapp has two of them. OS: Linux arch 4.1.6-1-ARCH #1 SMP PREEMPT Mon Aug 17 09:07:24 CEST 2015 i686 GNU/Linux from arch pacman: perl-parse-yapp 1.05-6 Here's a diff of the fix I've made: --- /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 17:36:15 1.1 +++ /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 17:39:16 1.2 @@ -880,7 +880,7 @@ return($1, [ $1, $lineno[0] ]); }; - $$input=~/\G{/gc + $$input=~/\G\{/gc and do { my($level,$from,$code); @@ -907,7 +907,7 @@ and return('START',[ undef, $lineno[0] ]); $$input=~/\G%(expect)/gc and return('EXPECT',[ undef, $lineno[0] ]); - $$input=~/\G%{/gc + $$input=~/\G%\{/gc and do { my($code);
On 2015-08-26 21:15:52, rklement@pacbell.net wrote: Show quoted text
> Perl v5.22.0 has deprecated using unescaped { in a regex. yapp has two > of them. > > OS: Linux arch 4.1.6-1-ARCH #1 SMP PREEMPT Mon Aug 17 09:07:24 CEST > 2015 i686 GNU/Linux > > from arch pacman: perl-parse-yapp 1.05-6 > > Here's a diff of the fix I've made: > > --- /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 > 17:36:15 1.1 > +++ /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 > 17:39:16 1.2 > @@ -880,7 +880,7 @@ > return($1, [ $1, $lineno[0] ]); > }; > > - $$input=~/\G{/gc > + $$input=~/\G\{/gc > and do { > my($level,$from,$code); > > @@ -907,7 +907,7 @@ > and return('START',[ undef, $lineno[0] ]); > $$input=~/\G%(expect)/gc > and return('EXPECT',[ undef, $lineno[0] ]); > - $$input=~/\G%{/gc > + $$input=~/\G%\{/gc > and do { > my($code);
This deprecation warning is now a fatal error with perl 5.25.1 and later.
On 2016-05-21 08:20:33, SREZIC wrote: Show quoted text
> On 2015-08-26 21:15:52, rklement@pacbell.net wrote:
> > Perl v5.22.0 has deprecated using unescaped { in a regex. yapp has two > > of them. > > > > OS: Linux arch 4.1.6-1-ARCH #1 SMP PREEMPT Mon Aug 17 09:07:24 CEST > > 2015 i686 GNU/Linux > > > > from arch pacman: perl-parse-yapp 1.05-6 > > > > Here's a diff of the fix I've made: > > > > --- /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 > > 17:36:15 1.1 > > +++ /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 > > 17:39:16 1.2 > > @@ -880,7 +880,7 @@ > > return($1, [ $1, $lineno[0] ]); > > }; > > > > - $$input=~/\G{/gc > > + $$input=~/\G\{/gc > > and do { > > my($level,$from,$code); > > > > @@ -907,7 +907,7 @@ > > and return('START',[ undef, $lineno[0] ]); > > $$input=~/\G%(expect)/gc > > and return('EXPECT',[ undef, $lineno[0] ]); > > - $$input=~/\G%{/gc > > + $$input=~/\G%\{/gc > > and do { > > my($code);
> > This deprecation warning is now a fatal error with perl 5.25.1 and later. >
See also: https://rt.perl.org/rt3/Ticket/Display.html?id=128139
On 2016-05-21 08:20:33, SREZIC wrote: Show quoted text
> On 2015-08-26 21:15:52, rklement@pacbell.net wrote:
> > Perl v5.22.0 has deprecated using unescaped { in a regex. yapp has two > > of them. > > > > OS: Linux arch 4.1.6-1-ARCH #1 SMP PREEMPT Mon Aug 17 09:07:24 CEST > > 2015 i686 GNU/Linux > > > > from arch pacman: perl-parse-yapp 1.05-6 > > > > Here's a diff of the fix I've made: > > > > --- /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 > > 17:36:15 1.1 > > +++ /usr/share/perl5/vendor_perl/Parse/Yapp/Parse.pm 2015/08/26 > > 17:39:16 1.2 > > @@ -880,7 +880,7 @@ > > return($1, [ $1, $lineno[0] ]); > > }; > > > > - $$input=~/\G{/gc > > + $$input=~/\G\{/gc > > and do { > > my($level,$from,$code); > > > > @@ -907,7 +907,7 @@ > > and return('START',[ undef, $lineno[0] ]); > > $$input=~/\G%(expect)/gc > > and return('EXPECT',[ undef, $lineno[0] ]); > > - $$input=~/\G%{/gc > > + $$input=~/\G%\{/gc > > and do { > > my($code);
> > This deprecation warning is now a fatal error with perl 5.25.1 and later. >
perl 5.26.0 RC1 is out now. The proposed patch is still needed and is still working.
From: ppisar [...] redhat.com
Dne St 26.srp.2015 21:15:52, rklement@pacbell.net napsal(a): Show quoted text
> Perl v5.22.0 has deprecated using unescaped { in a regex. yapp has two > of them. >
A proper patch for the sources is attached.
Subject: Parse-Yapp-1.05-Fix-unescaped-curly-bracket-in-regexps.patch
From d2f95da0bde7130cce98bbd91dc2095df3635bd4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com> Date: Mon, 22 May 2017 11:14:40 +0200 Subject: [PATCH] Fix unescaped curly bracket in regexps MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since 5.22.0 a literal '{' is a warning, since 5.26.0 it's an error: Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/\G{ <-- HERE / at YappParse.yp line 288. [...] CPAN RT#106685 CPAN RT#114776 Signed-off-by: Petr Písař <ppisar@redhat.com> --- YappParse.yp | 4 ++-- lib/Parse/Yapp/Parse.pm | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/YappParse.yp b/YappParse.yp index 9f6c234..8000b34 100644 --- a/YappParse.yp +++ b/YappParse.yp @@ -285,7 +285,7 @@ sub _Lexer { return($1, [ $1, $lineno[0] ]); }; - $$input=~/\G{/gc + $$input=~/\G\{/gc and do { my($level,$from,$code); @@ -312,7 +312,7 @@ sub _Lexer { and return('START',[ undef, $lineno[0] ]); $$input=~/\G%(expect)/gc and return('EXPECT',[ undef, $lineno[0] ]); - $$input=~/\G%{/gc + $$input=~/\G%\{/gc and do { my($code); diff --git a/lib/Parse/Yapp/Parse.pm b/lib/Parse/Yapp/Parse.pm index db561de..9651fa7 100755 --- a/lib/Parse/Yapp/Parse.pm +++ b/lib/Parse/Yapp/Parse.pm @@ -880,7 +880,7 @@ sub _Lexer { return($1, [ $1, $lineno[0] ]); }; - $$input=~/\G{/gc + $$input=~/\G\{/gc and do { my($level,$from,$code); @@ -907,7 +907,7 @@ sub _Lexer { and return('START',[ undef, $lineno[0] ]); $$input=~/\G%(expect)/gc and return('EXPECT',[ undef, $lineno[0] ]); - $$input=~/\G%{/gc + $$input=~/\G%\{/gc and do { my($code); -- 2.9.4
This issue is now resolved.