gbranden pushed a commit to branch master
in repository groff.

commit f85327ca299fcdddbc27bdd4c1f37f4385f73912
Author: G. Branden Robinson <[email protected]>
AuthorDate: Wed Feb 18 20:25:36 2026 -0600

    [mm]: Regression-test Savannah #68059.
    
    Marked list (`ML`) macro calls were not paying any attention to an
    (optional) third argument, the presence of which suppresses pre-item
    vertical space.
    
    * contrib/mm/tests/ML-honors-third-argument.sh: Do it.
    
    * contrib/mm/mm.am (mm_TESTS): Run test.
    
    Test fails at this commit.
---
 contrib/mm/ChangeLog                         | 10 ++++++
 contrib/mm/mm.am                             |  1 +
 contrib/mm/tests/ML-honors-third-argument.sh | 52 ++++++++++++++++++++++++++++
 3 files changed, 63 insertions(+)

diff --git a/contrib/mm/ChangeLog b/contrib/mm/ChangeLog
index 0e0677f97..071b3095b 100644
--- a/contrib/mm/ChangeLog
+++ b/contrib/mm/ChangeLog
@@ -1,3 +1,13 @@
+2026-02-18  G. Branden Robinson <[email protected]>
+
+       Add regression test for Savannah #68059.  Marked list (`ML`)
+       macro calls were not paying any attention to an (optional) third
+       argument, the presence of which suppresses pre-item vertical
+       space.
+
+       * tests/ML-honors-third-argument.sh: Do it.
+       * mm.am (mm_TESTS): Run test.
+
 2026-02-18  G. Branden Robinson <[email protected]>
 
        * m.tmac (ML): Handle explicitly empty second argument.
diff --git a/contrib/mm/mm.am b/contrib/mm/mm.am
index 57284e17f..091071710 100644
--- a/contrib/mm/mm.am
+++ b/contrib/mm/mm.am
@@ -73,6 +73,7 @@ mm_TESTS = \
   contrib/mm/tests/LT-SP-multi-word-LO-SJ-works.sh \
   contrib/mm/tests/LT-should-space-after-inside-address.sh \
   contrib/mm/tests/ML-accepts-empty-second-argument.sh \
+  contrib/mm/tests/ML-honors-third-argument.sh \
   contrib/mm/tests/ML-marks-work.sh \
   contrib/mm/tests/MT-1-reports-all-TM-numbers.sh \
   contrib/mm/tests/MT-5-includes-AT-in-SG.sh \
diff --git a/contrib/mm/tests/ML-honors-third-argument.sh 
b/contrib/mm/tests/ML-honors-third-argument.sh
new file mode 100755
index 000000000..d27d805f4
--- /dev/null
+++ b/contrib/mm/tests/ML-honors-third-argument.sh
@@ -0,0 +1,52 @@
+#!/bin/sh
+#
+# Copyright 2026 G. Branden Robinson
+#
+# This file is part of groff, the GNU roff typesetting system.
+#
+# groff is free software; you can redistribute it and/or modify it under
+# the terms of the GNU General Public License as published by the Free
+# Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# groff is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+# for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+groff="${abs_top_builddir:-.}/test-groff"
+
+# Regression-test Savannah #68059.
+
+input='.
+.P
+This is an
+.I mm
+document using an
+.B ML
+marked list that attempts to suppress vertical spacing
+before each list item
+by specifying a third argument to the
+.B ML
+call.
+.ML * "" 1
+.LI
+alpha
+.LI
+beta
+.LI
+gamma
+.LE
+.'
+
+output=$(echo "$input" | "$groff" -m m -T ascii -P -cbou \
+    | head -n 18 | nl -ba)
+echo "$output"
+
+echo "$output" \
+    | grep -Eq '^ +13[         ]+\* *beta' # 1 space, 1 tab in brackets
+
+# vim:set autoindent expandtab shiftwidth=4 tabstop=4 textwidth=72:

_______________________________________________
groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit

Reply via email to