On Tue, Apr 12, 2005 at 03:05:56PM +0200, Rafael Laboissiere wrote: > * Rafael Laboissiere <[EMAIL PROTECTED]> [2005-04-12 12:16]: > > In PDL::Reduce.pm.gz there are many instances of: > > > > \f(CW\*(C`reduce\*(C'\fR > > > > which seems to be a perfectly acceptable nroff construct. > > > > The whatis program seems to scan the "NAME" section of man pages and display > > the contents. However, whatis seems to do some kind of parsing also, by > > removing the "\f(CW" and "\fR" as above. > > > > My question is: wouldn't it be simpler to fix the whatis program in the > > man-db package, such that the construct above is correctly parsed and > > produces something like: > > > > $ whatis PDL::Reduce > > PDL::Reduce (3pm) - - a "reduce" function for PDL > > > > ? > > > > I am Cc:ing this message to [EMAIL PROTECTED] > > I investigated the issue a little further. the "\*(C`" and "\*(C'" escape > sequences are defined in the preamble of man pages generated by Pod::Man as > string sequences: > > .ds C` "" > .ds C' "" > > The whatis program just reads the synopsis lines extracted by the mandb > program and stored in /var/cache/man/index.db. The mandb program would > have to be changed in order to cope with the .ds definitions above. I > guess that this is a not-so-trivial problem.
Indeed. Right now, lexgrog is not even close to being able to parse *roff at this level. Even if I were to implement that, other implementations of whatis can't handle this either. For portability, you should avoid constructs like that in the NAME section. -- Colin Watson [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]