groff-commit
[Top][All Lists]
Advanced

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

[groff] 20/31: tmac/papersize.tmac: Improve diagnostic message.


From: G. Branden Robinson
Subject: [groff] 20/31: tmac/papersize.tmac: Improve diagnostic message.
Date: Sun, 30 May 2021 11:12:35 -0400 (EDT)

gbranden pushed a commit to branch master
in repository groff.

commit dcc38ebd122864a66aa23ba8f0e1bf468a0c5344
Author: G. Branden Robinson <g.branden.robinson@gmail.com>
AuthorDate: Sun May 30 11:18:40 2021 +1000

    tmac/papersize.tmac: Improve diagnostic message.
    
    * tmac/papersize.tmac: Improve diagnostic message; when complaining
      about unrecognized input, report back the input we actually received,
      not what it looks like after we transform it.  Also add name of macro
      package to diagnostic so the user knows who is speaking, continuing
      the long process of fixing Savannah #52463.
---
 ChangeLog           | 9 +++++++++
 tmac/papersize.tmac | 4 +++-
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 60767f8..1a596ba 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,14 @@
 2021-05-29  G. Branden Robinson <g.branden.robinson@gmail.com>
 
+       * tmac/papersize.tmac: Improve diagnostic message; when
+       complaining about unrecognized input, report back the input we
+       actually received, not what it looks like after we transform it.
+       Also add name of macro package to diagnostic so the user knows
+       who is speaking, continuing the long process of fixing Savannah
+       #52463.
+
+2021-05-29  G. Branden Robinson <g.branden.robinson@gmail.com>
+
        * tmac/groff_ms.7.man (Usage/Paragraphs) <QP>: Fix error; .QP
        paragraphs are indented by \n[QI], not \n[PI].
 
diff --git a/tmac/papersize.tmac b/tmac/papersize.tmac
index 58abb56..4a86e0e 100644
--- a/tmac/papersize.tmac
+++ b/tmac/papersize.tmac
@@ -106,6 +106,8 @@
 .  ds paper-dl-length 22c
 .  ds paper-dl-width 11c
 .
+.  \" Save the input parameter for a later diagnostic.
+.  ds paper-arg \*[paper]\"
 .  \" We assume that letters a-z and A-Z aren't mapped during start-up.
 .  tr AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz
 .  di lowercase
@@ -150,7 +152,7 @@
 .    nr paper-w 1
 .
 .  ie \n[paper-w] \
-.    tm warning: Unknown paper size '\*[paper]'
+.    tm papersize.tmac: warning: unrecognized paper size '\*[paper-arg]'
 .  el \
 .    if !r LL \
 .      nr LL \n[.l]u  \" for ms, mdoc, man



reply via email to

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