bugGNU roff - Bugs: bug #54473, chess_board.roff: Many registers...

 
 

bug #54473: chess_board.roff: Many registers are not defined

Submitter:  Bjarni Ingi Gislason <bjarniig>
Submitted:  Wed 08 Aug 2018 09:23:20 PM UTC
   
 
Category:  Macro - others/general Severity:  2 - Minor
Item Group:  Lint Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 10 Jun 2022 12:43:07 AM UTC, comment #3: 

  Patches were made when the suffix '-u' was used, so I could have
missed deleting it here.

Patch is in the attachment.

1)

    contrib/hdtbl/examples/chess_board.roff: reduce the size of each
chess field by 1 millimeter.  This fits then on a A4 size paper with
margins of total size of 2 inches.
 
2)

    contrib/hdtbl/hdmisc.tmac: Define register '<<'.

      The numeric register '<<' is only used once in the "hdtbl"-source.
    Its meaning is unknown.  Its value is set to '0' by groff, which can
    issue a warning about this undefined register.

      This is one part of bug-report #54473 Chess_board.roff: Many
registers are not defined.

3)

    contrib/hdtbl/hdmisc.tmac: fix definition of register '<<'

      Make the definition of '<<' depend on whether it was defined on
the command line or not.
 
  Drop the "Its meaning is unknown".  Ingo had a remark about it.  Now
his explanation can be checked with different values of '<<' on the
command line.

4)

    contrib/hdtbl/hdmisc.tmac: Initialize register 'M#'

      The register 'M#' has been used undefined.  Fix that.

5)

    hdmisc.tmac: Avoid a warning about a tab character in this source

      An example of the warnings:

    ../contrib/hdtbl/hdmisc.tmac:306: backtrace: macro 't*DI'
    ../contrib/hdtbl/hdtbl.tmac:477: backtrace: macro 'ETB'
    ../contrib/hdtbl/examples/common.roff:50: backtrace: macro 'H'
    troff: ../contrib/hdtbl/examples/chess_board.roff:45: warning: tab
character in unquoted macro argument

6)

    hdmisc.tmac: macro t*index: Fix the end value of a while loop

      The end value for the comparison of the strings is too large.

      Check if the second string is longer than the first one.

7)

    hdtbl.tmac: restore line length with minimal horizontal resolution

8)

"%beginstrip%" can occur in the patch set.

9)

    contrib/hdtbl/hdtbl.tmac: comment out tabs after ".di" as they
cause warnings
 
10)

    contrib/hdtbl/hdtbl.tmac: Avoid a warning about undefined macros

      Initialize the string variables "t*held" and "t*kept" to empty
before they are tested with: !""\\*[t*...]" .

11)

    hdmisc.tmac: Avoid a warning about a tab character in this source

      An example of the warnings:

    ../contrib/hdtbl/hdmisc.tmac:306: backtrace: macro 't*DI'
    ../contrib/hdtbl/hdtbl.tmac:477: backtrace: macro 'ETB'
    ../contrib/hdtbl/examples/common.roff:50: backtrace: macro 'H'
    troff: ../contrib/hdtbl/examples/chess_board.roff:45: warning: tab
character in unquoted macro argument


12)

    Subject: hdtbl.tmac and common.roff: fix undefined strings and
remove 'substring'

    hdtbl.tmac:

      Strings "t*held" and "t*kept" are defined by using itself instead
of
    adding the text to them; use ".as a ..." instead of ".ds a \*[a]
..."

    common.roff:

      The "substring" request is not needed as there is no longer a
    possibility to overflow.

13)

    src: hdtbl.tmac: Fix one formatting and one bug

      Increase space between sentences.

      The escape '\c' removes everything after it, except "\R..." ("info
groff").


(file #53290)

Bjarni Ingi Gislason <bjarniig>
Tue 31 May 2022 11:48:45 PM UTC, comment #2: 

We now have a item group for this sort of thing: "Lint".

The resulting document renders just fine for me (at least, it looks like what it claims to be), so the severity of this ticket is "Minor" (as also strongly implied the "Lint" item group).

Making the hdtbl examples quiescent with troff's -ww option is a reasonable objective.

Patches welcome.

G. Branden Robinson <gbranden>
Group administrator
Mon 13 Aug 2018 07:53:24 PM UTC, comment #1: 

This ticket should be deleted, or at least closed as invalid. See #54475 for details.

Ingo Schwarze <schwarze>
Group Member
Wed 08 Aug 2018 09:23:20 PM UTC, original submission:  


Subject: chess_board.roff: Many registers are not defined.

  For example

troff: ../contrib/hdtbl/examples/chess_board.roff:45: warning: number register 'rspan1*1*1' not defined
./contrib/hdtbl/hdtbl.tmac:416: backtrace: while loop
./contrib/hdtbl/hdtbl.tmac:516: backtrace: macro 't*divs'
./contrib/hdtbl/hdtbl.tmac:348: backtrace: macro 'ETB'
../contrib/hdtbl/examples/common.roff:50: backtrace: macro 'H'

  All diagnostics are in the attachment (file "chess_board.roff.warnings").

Bjarni Ingi Gislason <bjarniig>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #53290:  chess_board.roff.diff added by bjarniig (8KiB - text/x-patch - 54473.patch)
file #44744:  chess_board.roff.warnings added by bjarniig (131KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by gbranden (Posted a comment)
  • -email is unavailable- added by bgarrigues (Updated the item)
  • -email is unavailable- added by schwarze (Posted a comment)
  • -email is unavailable- added by bjarniig (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 12 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2022-06-10 bjarniig Attached File- Added chess_board.roff.diff, #53290
    2022-05-31 gbranden Item GroupWarning/Suspicious behaviour Lint
        StatusInvalid None
    2020-11-02 barx Carbon-CopyRemoved 93119 -
    2020-11-02 barx SummarySubject: chess_board.roff: Many registers are not defined chess_board.roff: Many registers are not defined
    2018-11-26 bgarrigues Severity1 - Wish 2 - Minor
        Item GroupFeature change Warning/Suspicious behaviour
    2018-08-13 schwarze CategoryNone Macro - others/general
        Severity3 - Normal 1 - Wish
        Item GroupBuild/Installation Feature change
        StatusNone Invalid
    2018-08-08 bjarniig Attached File- Added chess_board.roff.warnings, #44744

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code