This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Split NAME line on multiple whitespaces
authorJames E Keenan <jkeenan@cpan.org>
Fri, 23 Nov 2018 22:13:59 +0000 (17:13 -0500)
committerJames E Keenan <jkeenan@cpan.org>
Sat, 24 Nov 2018 00:04:06 +0000 (19:04 -0500)
For:  RT # 133683

pod/perlmodlib.pod is a file generated by pod/perlmodlib.PL, which is
run by 'miniperl' during 'make'.  That program parses the 'NAME' header
of .pod files and fragments of POD found in 'regen/opcode.pl'.  The POD
for B::Op_private is one such fragment.  Correcting a superfluous
whitespace in that fragment did not suffice to prevent the downstream
formatting error reported in the RT -- an error visible with 'pod2text'
and 'pod2html' as well.  We also had to make the regex which
perlmodlib.PL uses to parse the 'NAME' header more flexible.

lib/B/Op_private.pm
pod/perlmodlib.PL
regen/opcode.pl

index 0c92038..5f98437 100644 (file)
@@ -14,7 +14,7 @@
 
 =head1 NAME
 
-B::Op_private -  OP op_private flag definitions
+B::Op_private - OP op_private flag definitions
 
 =head1 SYNOPSIS
 
index c33f692..bfc7860 100644 (file)
@@ -74,7 +74,7 @@ for my $filename (@files) {
     close MOD
         or die "Error closing $filename: $!";
 
-    ($name, $thing) = split / --? /, $title, 2;
+    ($name, $thing) = split /\s+--?\s+/, $title, 2;
 
     unless ($name and $thing) {
        warn "$filename missing name\n"  unless $name;
index 0117866..672f55c 100755 (executable)
@@ -404,7 +404,7 @@ sub print_B_Op_private {
     my $header = <<'EOF';
 @=head1 NAME
 @
-@B::Op_private -  OP op_private flag definitions
+@B::Op_private - OP op_private flag definitions
 @
 @=head1 SYNOPSIS
 @