[bug #68445] [troff] spurious warning when using `.bd TR 500` followed by garbage invalid in a numeric expression
Deri James <[email protected]> Sat, 13 Jun 2026 13:06:05 -0400 (EDT)
| Newsgroups | gmane.comp.printing.groff.bugs |
|---|---|
| Message-ID | <[email protected]> |
Follow-up Comment #6, bug #68445 (group groff):
[comment #5 comment #5:]
> Okay, I may have a fix for this, but I couldn't pull on this thread without
> tugging on bug #68256 as well.
>
> Here's the new behavior. The "debug" output will go away.
>
> $ printf '.bd TR 500\t\\" Comment\n' | ./build/test-groff -ww 2>&1 | grep .
> || echo NO OUTPUT
> troff:<standard input>:1: debug: GBR: emboldening is conditional because
> first argument starts with non-numeral, character 'T'
> troff:<standard input>:1: warning: no font mounted at position 500 [-w font]
> troff:<standard input>:1: error: cannot select font for conditional
> emboldening
>
> What do you think? I'll next go to bug #68256 and run this new code through
> your most recent scenarios, and see how it fares.
The first syntax form:-
.bd font [offset]
specifies that "font can be either a non-negative font position or the name of
a font.". So ".bd TR 500" is a perfectly valid form 1 syntax, rather than an
invalid second form. You cannot assume it is the conditional form simply
because arg1 is non-numeric!!
I have written a lot more at bug #68256.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?68445>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
signature.asc
(application/pgp-signature, 228 B)
-----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQQk97aszIMMAvLLwm6qLAuaBUf3TgUCai2N/QAKCRCqLAuaBUf3 TgvXAQDFBmJStyjhgTeUqFp4t2Y1Q/bBpozpfvaPhnATtgLa0wD7BljmqnSE+NGx vwHoGtkyNVLyUiW9izW4WuRd5wA/dQE= =FzHv -----END PGP SIGNATURE-----