From: Russ Allbery Date: Thu, 19 Jul 2001 15:52:37 +0000 (-0700) Subject: Re: [PATCH: perl@11373] pod fixups for pod/perlhack.pod X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=aa212ad6bac1d6418641d6202980bfcb97513e73;p=p5sagit%2Fp5-mst-13.2.git Re: [PATCH: perl@11373] pod fixups for pod/perlhack.pod Message-Id: p4raw-id: //depot/perl@11416 --- diff --git a/lib/Pod/Man.pm b/lib/Pod/Man.pm index 669e04b..9c6eba0 100644 --- a/lib/Pod/Man.pm +++ b/lib/Pod/Man.pm @@ -1,5 +1,5 @@ # Pod::Man -- Convert POD data to formatted *roff input. -# $Id: Man.pm,v 1.19 2001/07/10 11:08:09 eagle Exp $ +# $Id: Man.pm,v 1.20 2001/07/19 22:51:11 eagle Exp $ # # Copyright 1999, 2000, 2001 by Russ Allbery # @@ -37,7 +37,7 @@ use vars qw(@ISA %ESCAPES $PREAMBLE $VERSION); # Don't use the CVS revision as the version, since this module is also in Perl # core and too many things could munge CVS magic revision strings. This # number should ideally be the same as the CVS revision in podlators, however. -$VERSION = 1.19; +$VERSION = 1.20; ############################################################################## @@ -569,7 +569,8 @@ sub sequence { } elsif (exists $ESCAPES{$_}) { return bless \ "$ESCAPES{$_}", 'Pod::Man::String'; } else { - carp "Unknown escape E<$1>"; + my ($file, $line) = $seq->file_line; + warn "$file:$line: Unknown escape E<$_>\n"; return bless \ "E<$_>", 'Pod::Man::String'; } } @@ -607,7 +608,8 @@ sub sequence { if ($command eq 'X') { push (@{ $$self{INDEX} }, $_); return '' } # Anything else is unknown. - carp "Unknown sequence $command<$_>"; + my ($file, $line) = $seq->file_line; + warn "$file:$line: Unknown sequence $command<$_>\n"; } @@ -702,7 +704,9 @@ sub cmd_back { my $self = shift; $$self{INDENT} = pop @{ $$self{INDENTS} }; unless (defined $$self{INDENT}) { - carp "Unmatched =back"; + my ($file, $line, $paragraph) = @_; + ($file, $line) = $paragraph->file_line; + warn "$file:$line: Unmatched =back\n"; $$self{INDENT} = 0; } if ($$self{WEIRDINDENT}) { @@ -1344,17 +1348,17 @@ invalid. A quote specification must be one, two, or four characters long. (W) The POD source contained a non-standard command paragraph (something of the form C<=command args>) that Pod::Man didn't know about. It was ignored. -=item Unknown escape EE%sE +=item %s:%d: Unknown escape EE%sE (W) The POD source contained an CE> escape that Pod::Man didn't know about. C%sE> was printed verbatim in the output. -=item Unknown sequence %s +=item %s:%d: Unknown sequence %s (W) The POD source contained a non-standard interior sequence (something of the form CE>) that Pod::Man didn't know about. It was ignored. -=item Unmatched =back +=item %s:%d: Unmatched =back (W) Pod::Man encountered a C<=back> command that didn't correspond to an C<=over> command.