Skip Menu |

This queue is for tickets about the PostScript-File CPAN distribution.

Report information
The Basics
Id: 49838
Status: resolved
Priority: 0/
Queue: PostScript-File

People
Owner: Nobody in particular
Requestors: cjm [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 1.01
Fixed in: 1.02



Subject: [PATCH] strip option does not work with Perl 5.10
From perl5101delta: A bugfix related to the handling of the `/m' modifier and `qr' resulted in a change of behaviour between 5.8.x and 5.10.0: # matches in 5.8.x, doesn't match in 5.10.0 $re = qr/^bar/; "foo\nbar" =~ /$re/m; PostScript::File is affected by this; it prevents 'strip' from working properly. The fix is simple and attached.
Subject: PostScript-File.5.10.patch
--- File.pm 2007-11-20 16:33:27.000000000 -0600 +++ File.pm 2009-09-19 02:23:48.028240527 -0500 @@ -16,8 +16,8 @@ sub check_file ($;$$); # global constants -my $rmspace = qr(^\s+); # remove leading spaces -my $rmcomment = qr(^\s+\(% .*\)?); # remove single line comments +my $rmspace = qr(^\s+)m; # remove leading spaces +my $rmcomment = qr(^\s+\(% .*\)?)m; # remove single line comments =head1 NAME
Let's see if we can get that patch to show up as text...
--- File.pm 2007-11-20 16:33:27.000000000 -0600 +++ File.pm 2009-09-19 02:23:48.028240527 -0500 @@ -16,8 +16,8 @@ sub check_file ($;$$); # global constants -my $rmspace = qr(^\s+); # remove leading spaces -my $rmcomment = qr(^\s+\(% .*\)?); # remove single line comments +my $rmspace = qr(^\s+)m; # remove leading spaces +my $rmcomment = qr(^\s+\(% .*\)?)m; # remove single line comments =head1 NAME
Patch applied in 1.02