File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -114,7 +114,8 @@ my $bom
114114sub hide_from_pause {
115115 my ( $self , $content , $file_name ) = @_ ;
116116 return 0 if defined ($file_name ) && $file_name =~ m {\. pm\. PL\z } ;
117- my $pkg = $self -> name;
117+ my $pkg = $self -> name;
118+ my $pkg_match = join q[ (?:::|')] , map quotemeta , split m { ::} , $pkg ;
118119
119120# This regexp is *almost* the same as $PKG_REGEXP in Module::Metadata.
120121# [b] We need to allow/ignore a possible BOM since we read in binary mode.
@@ -128,7 +129,7 @@ sub hide_from_pause {
128129 [\h\{ ;]* # intro chars on a line [s]
129130 package # the word 'package'
130131 \h + # whitespace [s]
131- (\Q $pkg \E ) # a package name [p]
132+ ($pkg_match ) # the package name [p]
132133 (\h + v?[0-9._]+)? # optional version number (preceded by whitespace) [v]
133134 \h * # optional whitesapce [s]
134135 [;\{ ] # semicolon line terminator or block start
You can’t perform that action at this time.
0 commit comments