diff options
author | Steve Peters <steve@fisharerojo.org> | 2005-12-08 19:04:59 +0000 |
---|---|---|
committer | Steve Peters <steve@fisharerojo.org> | 2005-12-08 19:04:59 +0000 |
commit | ce6e48f380e7ead67a463a86546c4ac2012ab015 (patch) | |
tree | d2bde08d913ce63c7a07f0764269d07b707be378 /lib | |
parent | 7eb7d786de9bebe120f2143ce65237684a3a5d80 (diff) | |
download | perl-ce6e48f380e7ead67a463a86546c4ac2012ab015.tar.gz |
Further yak-shaving on Pod::Usage. Now, t/pod/pod2usage2.t tests
pass.
p4raw-id: //depot/perl@26304
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Pod/Usage.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Pod/Usage.pm b/lib/Pod/Usage.pm index eee915e1d4..ed4b81dce2 100644 --- a/lib/Pod/Usage.pm +++ b/lib/Pod/Usage.pm @@ -594,9 +594,11 @@ sub seq_i { return $_[1] } # Note that the below is very, very specific to Pod::Text. sub _handle_element_end { my ($self, $element) = @_; - if ($element eq 'head1' && $self->{USAGE_OPTIONS}->{-verbose} < 2) { + if ($element eq 'head1') { $$self{USAGE_HEAD1} = $$self{PENDING}[-1][1]; - $$self{PENDING}[-1][1] =~ s/^\s*SYNOPSIS\s*$/USAGE/; + if ($self->{USAGE_OPTIONS}->{-verbose} < 2) { + $$self{PENDING}[-1][1] =~ s/^\s*SYNOPSIS\s*$/USAGE/; + } } elsif ($element eq 'head2') { $$self{USAGE_HEAD2} = $$self{PENDING}[-1][1]; } |