This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Refactor File::DosGlob to avoid an unescaped { in a regex.
authorNicholas Clark <nick@ccl4.org>
Sun, 3 Jun 2012 20:39:50 +0000 (22:39 +0200)
committerNicholas Clark <nick@ccl4.org>
Sun, 3 Jun 2012 20:39:50 +0000 (22:39 +0200)
This avoids generating deprecation warnings.

lib/File/DosGlob.pm
pod/perldelta.pod

index e6d548e..111ec20 100644 (file)
@@ -6,7 +6,7 @@
 
 package File::DosGlob;
 
-our $VERSION = '1.07';
+our $VERSION = '1.08';
 use strict;
 use warnings;
 
@@ -166,9 +166,7 @@ sub glob {
        }
       }
       for ( @pat ) {
-       s/\\{/{/g;
-       s/\\}/}/g;
-       s/\\,/,/g;
+       s/\\([{},])/$1/g;
       }
       #print join ("\n", @pat). "\n";
  
index 946f3f7..4f3483e 100644 (file)
@@ -103,6 +103,12 @@ XXX
 
 =item *
 
+L<File::DosGlob> has been upgraded from version 1.07 to 1.08.
+
+There are no visible changes, only minor internal refactorings.
+
+=item *
+
 L<IO> has been upgraded from version 1.25_06 to version 1.25_07.
 
 C<sync()> can now be called on read only file handles [perl #64772].