Skip Menu |

This queue is for tickets about the podlators CPAN distribution.

Report information
The Basics
Id: 132007
Status: open
Priority: 0/
Queue: podlators

People
Owner: Nobody in particular
Requestors: dima [...] secretsauce.net
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: pod2man produces bogus output
Date: Thu, 27 Feb 2020 17:44:00 -0800
To: bug-podlators [...] rt.cpan.org
From: Dima Kogan <dima [...] secretsauce.net>
Hi. Let's say I have this tst.pod file: ====================================================== =head1 abc EVT_...() VT_...() T_...() _...() ...() EVT_...() EVT_..() EVT_.() EVT_() EVT() EVT_...() EVT_...( EVT_... EVT_.. EVT_. ====================================================== I run pod2man: ====================================================== $ pod2man tst.pod ... \&\s-1EVT_...\\fBs0()\fR \&\s-1VT_...\\fBs0()\fR T_...() _...() \&...() \&\s-1EVT_...\\fBs0()\fR \&\s-1EVT_..\\fBs0()\fR \&\s-1EVT_.\\fBs0()\fR \&\s-1\fBEVT_\s0()\fR \&\s-1\fBEVT\s0()\fR \&\s-1EVT_...\\fBs0()\fR \&\s-1EVT_...\s0( \&\s-1EVT_... EVT_.. EVT_.\s0 ... ====================================================== Spaces added for clarity, and only the interesting things kept. Note that sometimes pod2man like to bold things, even I never asked for it (\\fB tags). And note that sometimes pod2man likes to add "s0", which is some sort of leftover code that is not interpreted by the "man" tool: "man" actually displays "s0", which is nowhere in the original text. My understanding is that POD markup is either - lines starting with =something - text such as B<something> or L<something> and such Is there some other type of markup that pod2man is trying to interpret that I'm accidentally including in tst.pod? I don't see anything clear in the "perlpod" manpage. Thanks.
Subject: Re: [rt.cpan.org #132007] pod2man produces bogus output
Date: Thu, 27 Feb 2020 19:19:03 -0800
To: "Dima Kogan via RT" <bug-podlators [...] rt.cpan.org>
From: Russ Allbery <rra [...] cpan.org>
"Dima Kogan via RT" <bug-podlators@rt.cpan.org> writes: Show quoted text
> Spaces added for clarity, and only the interesting things kept. Note > that sometimes pod2man like to bold things, even I never asked for it > (\\fB tags).
Show quoted text
> And note that sometimes pod2man likes to add "s0", which is some sort of > leftover code that is not interpreted by the "man" tool: "man" actually > displays "s0", which is nowhere in the original text.
This is a definite bug in the interaction between magic application of small caps markup and magic application of function bolding. Thanks. Now fixed in Git. Show quoted text
> My understanding is that POD markup is either
Show quoted text
> - lines starting with =something > - text such as B<something> or L<something> and such
Show quoted text
> Is there some other type of markup that pod2man is trying to interpret > that I'm accidentally including in tst.pod? I don't see anything clear > in the "perlpod" manpage.
Pod::Man hints at this, although the documentation is inadequate on the details. Besides the obvious pod conversions, Pod::Man also takes care of formatting func(), func(3), and simple variable references like $foo or @bar so you don't have to use code escapes for them; complex expressions like $fred{'stuff'} will still need to be escaped, though. It also translates dashes that aren't used as hyphens into en dashes, makes long dashes--like this--into proper em dashes, fixes "paired quotes," makes C++ look right, puts a little space between double underscores, makes ALLCAPS a teeny bit smaller in troff, and escapes stuff that *roff treats as special so that you don't have to. This is one of those things that was probably a bad decision but that was made so long ago (it was a feature of Tom Christiansen's original pod2man script when I took it over in 1999, and with which I was trying to remain backward-compatible) that changing it is a substantial break of backward compatibility, so I've been reluctant to do so. I have another long-awaited backward-compatibility break to turn on Unicode output by default. Maybe I should turn guesswork off by default as well and call that a 5.00 release and see what the fallout is. -- #!/usr/bin/perl -- Russ Allbery, Just Another Perl Hacker $^=q;@!>~|{>krw>yn{u<$$<[~||<Juukn{=,<S~|}<Jwx}qn{<Yn{u<Qjltn{ > 0gFzD gD, 00Fz, 0,,( 0hF 0g)F/=, 0> "L$/GEIFewe{,$/ 0C$~> "@=,m,|,(e 0.), 01,pnn,y{ rw} >;,$0=q,$,,($_=$^)=~y,$/ C-~><@=\n\r,-~$:-u/ #y,d,s,(\$.),$1,gee,print