bug-groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #61408] [man] empty \*[an-extra1] provokes warnings


From: G. Branden Robinson
Subject: [bug #61408] [man] empty \*[an-extra1] provokes warnings
Date: Tue, 2 Nov 2021 06:21:59 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0

Update of bug #61408 (project groff):

                  Status:                    None => Confirmed              
             Assigned to:                    None => gbranden               
                 Summary: [man] Warning about an empty \*[an-extra1] => [man]
empty \*[an-extra1] provokes warnings

    _______________________________________________________

Follow-up Comment #1:

[comment #0 original submission:]
> [man] Warning about an empty \*[an-extra1]
> 
>   "man patch" causes warnings:
> 
> troff: backtrace: '/home/bg/git/groff/build/s-tmac/an.tmac':273: macro
'an-prepare-inner-footer'
> troff: backtrace: '/home/bg/git/groff/build/s-tmac/an.tmac':350: macro
'an-footer'
> troff: backtrace: '/home/bg/git/groff/build/s-tmac/an.tmac':61: trap-called
macro 'an-end'
> troff: warning: start (0) and end (0) index of substring out of range
> 
>   This is caused by the line
> 
> .TH PATCH 1 "" GNU
> 
> 
> line 61 corresponds to line an-footer
> line 273      -"-            substring an-half-cfoot 0
\\n[an-half-cfoot-length]
> line 350      -"-            an-prepare-inner-footer
> 

Thanks, Bjarni.  I can confirm.

My diagnostic output is a little different (leaving aside file system
differences); this is further evidence that your Git branch is somewhat
different from mine.

Try this command.


git diff origin/master master


You might want to follow-up to the groff@ list to get advice on how to move
your personal branch to something that makes it easier for you to test the
Savannah master branch in parallel with your own.

I also note that with the CHECKSTYLE register set to a true value, the user
gets warned about the cause of the problem, but this is not documented and
even if it were I have little hope that most man page writers would use it. 
:-/


$ echo '.TH patch 1 "" GNU' | tgu -man -rCHECKSTYLE=1
an.tmac:<standard input>:1: style: .TH missing third argument; suggest
document modification date in ISO 8601 format (YYYY-MM-DD)
troff: backtrace: '.../groff/build/../tmac/an.tmac':403: macro
'an-prepare-inner-footer'
troff: backtrace: '.../groff/build/../tmac/an.tmac':493: macro 'an-footer'
troff: backtrace: '.../groff/build/../tmac/an.tmac':111: trap-called macro
'an-end'
troff: warning: start and end index of substring out of range


I did indeed assume a nonempty `an-extra1` string.  I will fix that.

I find myself tempted to give it a fallback value.


.ds extra1 "Holocene epoch\" :-|


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?61408>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]