groff-commit
[Top][All Lists]
Advanced

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

[groff] 03/03: ms: Cease warning level manipulation.


From: G. Branden Robinson
Subject: [groff] 03/03: ms: Cease warning level manipulation.
Date: Thu, 6 Feb 2020 01:20:27 -0500 (EST)

gbranden pushed a commit to branch master
in repository groff.

commit 5aa934e701ac96c48cad71eae39ddb5817a7399c
Author: G. Branden Robinson <address@hidden>
AuthorDate: Thu Feb 6 17:17:38 2020 +1100

    ms: Cease warning level manipulation.
    
    Stop ms macro package from manipulating warnings.
    
    * tmac/s.tmac: Remove code block that attempted to enable all
      warnings "only if none are given on the command line".  It did this by
      simply comparing the value of the warn register (\n[.warn]) against
      the default value; but of course, a user could specify -w options that
      exactly matched the default and the test would not be able to tell,
      causing puzzling and undesired behavior.  Furthermore, the hard-coded
      default was out of date and did not correspond to recent releases of
      groff.  If you want all warnings on, use the ".warn" request with no
      arguments in your ms document or pass "-w w" to groff (see troff(1) or
      the Texinfo manual for more on warnings).
    
    Thanks to Bjarni Ingi Gislason for bringing this issue to our attention.
    
    Resolves <https://savannah.gnu.org/bugs/?57583>.
---
 ChangeLog   | 30 +++++++++++++++++++++++++++---
 NEWS        |  4 ++++
 tmac/s.tmac |  3 ---
 3 files changed, 31 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index ee16c7b..2301e1b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,28 @@
+2020-02-06  G. Branden Robinson <address@hidden>
+
+       Stop ms macro package from manipulating warnings.
+
+       * tmac/s.tmac: Remove code block that attempted to enable all
+       warnings "only if none are given on the command line".  It did
+       this by simply comparing the value of the warn register
+       {\n[.warn]} against the default value; but of course, a user
+       could specify -w options that exactly matched the default and
+       the test would not be able to tell, causing puzzling and
+       undesired behavior.  Furthermore, the hard-coded default was out
+       of date and did not correspond to recent releases of groff.  If
+       you want all warnings on, use the ".warn" request with no
+       arguments in your ms document or pass "-w w" to groff (see
+       troff(1) or the Texinfo manual for more on warnings).
+
+       Thanks to Bjarni Ingi Gislason for bringing this issue to our
+       attention.
+
+       Resolves <https://savannah.gnu.org/bugs/?57583>.
+
 2020-01-18  Ingo Schwarze  <address@hidden>
 
-       Accept any number of arguments for .Dd in the groff_mdoc(7) macros.
+       Accept any number of arguments for .Dd in the groff_mdoc(7)
+       macros.
 
        * tmac/doc-common-u: The .Dd macro behaved in a weird way:
        Without arguments, it printed the string "Epoch".
@@ -134,7 +156,8 @@
 
 2019-12-21  Ingo Schwarze  <address@hidden>
 
-       Update NetBSD, OpenBSD, FreeBSD, Darwin, and DragonFly version strings.
+       Update NetBSD, OpenBSD, FreeBSD, Darwin, and DragonFly version
+       strings.
 
        * tmac/doc-common-u: Update.
        * tmac/groff_mdoc.7.man: Synchronize.
@@ -363,7 +386,8 @@
 
 2019-01-12  Ingo Schwarze  <address@hidden>
 
-       Correctly handle groff_mdoc(7) .Lk arguments starting with a dot.
+       Correctly handle groff_mdoc(7) .Lk arguments starting with a
+       dot.
 
        * tmac/doc.tmac-u: Each argument to the .Lk macro is printed
        on its own roff input line.  If it happens to start with a dot
diff --git a/NEWS b/NEWS
index 086cc5a..affbc23 100644
--- a/NEWS
+++ b/NEWS
@@ -48,6 +48,10 @@ o The an (man) macro package supports new CS and CT number 
registers to
   and maintainers of man(1) implementations) a way to view the rendered page
   elements in full capitals if desired.
 
+o The ms macro package no longer manipulates the warning level.  If you want
+  all warnings on, use the ".warn" request with no arguments in your ms
+  document or pass "-w w" to groff (see troff(1) or the Texinfo manual for
+  more on warnings).
 
 VERSION 1.22.4
 ==============
diff --git a/tmac/s.tmac b/tmac/s.tmac
index 1d0b0ae..8d46d43 100644
--- a/tmac/s.tmac
+++ b/tmac/s.tmac
@@ -23,9 +23,6 @@ along with this program.  If not, see 
<http://www.gnu.org/licenses/>.
 .if !\n(.g .ab These ms macros require groff.
 .if \n(.C \
 .      ab The groff ms macros do not work in compatibility mode.
-.\" Enable warnings (only if none are given on the command line).
-.\" You can delete this if you want.
-.if (\n[.warn] == 65543) .warn
 .\" See if already loaded.
 .if r GS .nx
 .mso devtag.tmac



reply via email to

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