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