summaryrefslogtreecommitdiff
path: root/regress
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@cvs.openbsd.org>2014-07-02 11:42:57 +0000
committerIngo Schwarze <schwarze@cvs.openbsd.org>2014-07-02 11:42:57 +0000
commiteb23be324e2d6141312f694f504b184ccf326d9b (patch)
tree2fbabacafcbfc24cca41fde40aa473069c1312a2 /regress
parentec55a547f2c134a78adccbca63f05be1cc2b66c8 (diff)
Clean up warnings related to macros and nesting.
* Hierarchical naming of enum mandocerr items. * Improve the wording to make it comprehensible. * Mention the offending macro. * Garbage collect one chunk of ancient, long unreachable code.
Diffstat (limited to 'regress')
-rw-r--r--regress/usr.bin/mandoc/man/TP/Makefile4
-rw-r--r--regress/usr.bin/mandoc/man/TP/double.in1
-rw-r--r--regress/usr.bin/mandoc/man/TP/double.out_lint5
-rw-r--r--regress/usr.bin/mandoc/man/nf/Makefile5
-rw-r--r--regress/usr.bin/mandoc/man/nf/dupe.in17
-rw-r--r--regress/usr.bin/mandoc/man/nf/dupe.out_ascii19
-rw-r--r--regress/usr.bin/mandoc/man/nf/dupe.out_lint2
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bd/Makefile3
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bd/break.out_lint1
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bd/broken.out_lint1
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bd/nested.out_lint2
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bf/Makefile3
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bf/break.out_lint1
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bf/broken.out_lint1
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bl/Makefile4
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bl/break.out_lint2
-rw-r--r--regress/usr.bin/mandoc/mdoc/Bl/broken.out_lint1
-rw-r--r--regress/usr.bin/mandoc/mdoc/Ns/Makefile5
-rw-r--r--regress/usr.bin/mandoc/mdoc/Ns/position.out_lint1
-rw-r--r--regress/usr.bin/mandoc/mdoc/Op/Makefile8
-rw-r--r--regress/usr.bin/mandoc/mdoc/Op/break.in29
-rw-r--r--regress/usr.bin/mandoc/mdoc/Op/break.out_lint3
-rw-r--r--regress/usr.bin/mandoc/mdoc/Op/broken.in24
-rw-r--r--regress/usr.bin/mandoc/mdoc/Op/broken.out_ascii11
-rw-r--r--regress/usr.bin/mandoc/mdoc/Op/broken.out_lint2
25 files changed, 145 insertions, 10 deletions
diff --git a/regress/usr.bin/mandoc/man/TP/Makefile b/regress/usr.bin/mandoc/man/TP/Makefile
index d5b74f160d1..7f3d995fe2e 100644
--- a/regress/usr.bin/mandoc/man/TP/Makefile
+++ b/regress/usr.bin/mandoc/man/TP/Makefile
@@ -1,6 +1,8 @@
-# $OpenBSD: Makefile,v 1.7 2014/04/08 07:13:01 schwarze Exp $
+# $OpenBSD: Makefile,v 1.8 2014/07/02 11:42:56 schwarze Exp $
REGRESS_TARGETS = badarg double literal longhead macrotag manyargs
REGRESS_TARGETS += sameline width
+LINT_TARGETS = double
+
.include <bsd.regress.mk>
diff --git a/regress/usr.bin/mandoc/man/TP/double.in b/regress/usr.bin/mandoc/man/TP/double.in
index 8d59f1f9fc5..4a6b1674a1b 100644
--- a/regress/usr.bin/mandoc/man/TP/double.in
+++ b/regress/usr.bin/mandoc/man/TP/double.in
@@ -27,6 +27,7 @@ at which point will this text wrap to the next line?
normal paragraph:
This is a rather long text because we want to test the text width;
at which point will this text wrap to the next line?
+.B
.PP
.TP 16n
.TP 16n
diff --git a/regress/usr.bin/mandoc/man/TP/double.out_lint b/regress/usr.bin/mandoc/man/TP/double.out_lint
new file mode 100644
index 00000000000..9040bc5224a
--- /dev/null
+++ b/regress/usr.bin/mandoc/man/TP/double.out_lint
@@ -0,0 +1,5 @@
+mandoc: double.in:20:2: WARNING: skipping paragraph macro: PP empty
+mandoc: double.in:21:2: WARNING: line scope broken: TP breaks TP
+mandoc: double.in:30:2: WARNING: line scope broken: PP breaks B
+mandoc: double.in:31:2: WARNING: skipping paragraph macro: PP empty
+mandoc: double.in:32:2: WARNING: line scope broken: TP breaks TP
diff --git a/regress/usr.bin/mandoc/man/nf/Makefile b/regress/usr.bin/mandoc/man/nf/Makefile
index b8f84c157b9..d3989b320c7 100644
--- a/regress/usr.bin/mandoc/man/nf/Makefile
+++ b/regress/usr.bin/mandoc/man/nf/Makefile
@@ -1,5 +1,6 @@
-# $OpenBSD: Makefile,v 1.5 2014/03/08 16:20:00 schwarze Exp $
+# $OpenBSD: Makefile,v 1.6 2014/07/02 11:42:56 schwarze Exp $
-REGRESS_TARGETS = indent args vert userdef
+REGRESS_TARGETS = indent args vert dupe userdef
+LINT_TARGETS = dupe
.include <bsd.regress.mk>
diff --git a/regress/usr.bin/mandoc/man/nf/dupe.in b/regress/usr.bin/mandoc/man/nf/dupe.in
new file mode 100644
index 00000000000..dfa1acbbb61
--- /dev/null
+++ b/regress/usr.bin/mandoc/man/nf/dupe.in
@@ -0,0 +1,17 @@
+.TH NF-DUPE 1 "July 2, 2014" OpenBSD
+.SH NAME
+nf-dupe \- duplicate filling macros
+.SH DESCRIPTION
+regular
+text
+.fi
+still
+regular
+text
+.nf
+literal
+text
+.nf
+still
+literal
+text
diff --git a/regress/usr.bin/mandoc/man/nf/dupe.out_ascii b/regress/usr.bin/mandoc/man/nf/dupe.out_ascii
new file mode 100644
index 00000000000..00236d21959
--- /dev/null
+++ b/regress/usr.bin/mandoc/man/nf/dupe.out_ascii
@@ -0,0 +1,19 @@
+NF-DUPE(1) OpenBSD Reference Manual NF-DUPE(1)
+
+
+
+NNAAMMEE
+ nf-dupe - duplicate filling macros
+
+DDEESSCCRRIIPPTTIIOONN
+ regular text
+ still regular text
+ literal
+ text
+ still
+ literal
+ text
+
+
+
+OpenBSD July 2, 2014 NF-DUPE(1)
diff --git a/regress/usr.bin/mandoc/man/nf/dupe.out_lint b/regress/usr.bin/mandoc/man/nf/dupe.out_lint
new file mode 100644
index 00000000000..b42e2b8cf41
--- /dev/null
+++ b/regress/usr.bin/mandoc/man/nf/dupe.out_lint
@@ -0,0 +1,2 @@
+mandoc: dupe.in:7:2: WARNING: fill mode already enabled, skipping .fi
+mandoc: dupe.in:14:2: WARNING: fill mode already disabled, skipping .nf
diff --git a/regress/usr.bin/mandoc/mdoc/Bd/Makefile b/regress/usr.bin/mandoc/mdoc/Bd/Makefile
index 2960117d412..609215b66ae 100644
--- a/regress/usr.bin/mandoc/mdoc/Bd/Makefile
+++ b/regress/usr.bin/mandoc/mdoc/Bd/Makefile
@@ -1,6 +1,7 @@
-# $OpenBSD: Makefile,v 1.9 2014/01/24 11:56:34 schwarze Exp $
+# $OpenBSD: Makefile,v 1.10 2014/07/02 11:42:56 schwarze Exp $
REGRESS_TARGETS = blank nested spacing empty offset-empty break broken
+LINT_TARGETS = nested break broken
# groff defect:
# - a display breaking another block continues indefinitely
diff --git a/regress/usr.bin/mandoc/mdoc/Bd/break.out_lint b/regress/usr.bin/mandoc/mdoc/Bd/break.out_lint
new file mode 100644
index 00000000000..51a667b8d81
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bd/break.out_lint
@@ -0,0 +1 @@
+mandoc: break.in:12:2: WARNING: blocks badly nested: Ed breaks Bo
diff --git a/regress/usr.bin/mandoc/mdoc/Bd/broken.out_lint b/regress/usr.bin/mandoc/mdoc/Bd/broken.out_lint
new file mode 100644
index 00000000000..53b71a9252c
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bd/broken.out_lint
@@ -0,0 +1 @@
+mandoc: broken.in:12:2: WARNING: blocks badly nested: Bc breaks Bd
diff --git a/regress/usr.bin/mandoc/mdoc/Bd/nested.out_lint b/regress/usr.bin/mandoc/mdoc/Bd/nested.out_lint
new file mode 100644
index 00000000000..5476f7d7049
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bd/nested.out_lint
@@ -0,0 +1,2 @@
+mandoc: nested.in:13:2: WARNING: nested displays are not portable: Bd in Bd
+mandoc: nested.in:24:2: WARNING: nested displays are not portable: Bd in Bd
diff --git a/regress/usr.bin/mandoc/mdoc/Bf/Makefile b/regress/usr.bin/mandoc/mdoc/Bf/Makefile
index ed22f8ea87c..f7f1b73b834 100644
--- a/regress/usr.bin/mandoc/mdoc/Bf/Makefile
+++ b/regress/usr.bin/mandoc/mdoc/Bf/Makefile
@@ -1,6 +1,7 @@
-# $OpenBSD: Makefile,v 1.2 2012/11/16 17:16:29 schwarze Exp $
+# $OpenBSD: Makefile,v 1.3 2014/07/02 11:42:56 schwarze Exp $
REGRESS_TARGETS = nest break broken
+LINT_TARGETS = break broken
# groff-1.20.1 defect:
# - If a font block breaks another block,
diff --git a/regress/usr.bin/mandoc/mdoc/Bf/break.out_lint b/regress/usr.bin/mandoc/mdoc/Bf/break.out_lint
new file mode 100644
index 00000000000..3422d187382
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bf/break.out_lint
@@ -0,0 +1 @@
+mandoc: break.in:13:2: WARNING: blocks badly nested: Ef breaks Bo
diff --git a/regress/usr.bin/mandoc/mdoc/Bf/broken.out_lint b/regress/usr.bin/mandoc/mdoc/Bf/broken.out_lint
new file mode 100644
index 00000000000..3cd1a19c6e9
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bf/broken.out_lint
@@ -0,0 +1 @@
+mandoc: broken.in:12:2: WARNING: blocks badly nested: Bc breaks Bf
diff --git a/regress/usr.bin/mandoc/mdoc/Bl/Makefile b/regress/usr.bin/mandoc/mdoc/Bl/Makefile
index a5154e4651a..4c15cba12f7 100644
--- a/regress/usr.bin/mandoc/mdoc/Bl/Makefile
+++ b/regress/usr.bin/mandoc/mdoc/Bl/Makefile
@@ -1,10 +1,12 @@
-# $OpenBSD: Makefile,v 1.17 2014/04/14 00:08:08 schwarze Exp $
+# $OpenBSD: Makefile,v 1.18 2014/07/02 11:42:56 schwarze Exp $
REGRESS_TARGETS = item inset diag ohang bullet dash enum hang tag
REGRESS_TARGETS += column extend nested
REGRESS_TARGETS += multitype multitag empty noIt bareTa unclosed break broken
+LINT_TARGETS = break broken
+
# groff-1.20.1 defects:
# - empty lists ruin indentation and sometimes cause empty lines
# - breaking lists continue indefinitely
diff --git a/regress/usr.bin/mandoc/mdoc/Bl/break.out_lint b/regress/usr.bin/mandoc/mdoc/Bl/break.out_lint
new file mode 100644
index 00000000000..79eade5f655
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bl/break.out_lint
@@ -0,0 +1,2 @@
+mandoc: break.in:13:2: WARNING: blocks badly nested: El breaks Bo
+mandoc: break.in:23:2: WARNING: blocks badly nested: El breaks Bd
diff --git a/regress/usr.bin/mandoc/mdoc/Bl/broken.out_lint b/regress/usr.bin/mandoc/mdoc/Bl/broken.out_lint
new file mode 100644
index 00000000000..ed70b672cb8
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Bl/broken.out_lint
@@ -0,0 +1 @@
+mandoc: broken.in:13:2: WARNING: blocks badly nested: Bc breaks Bl
diff --git a/regress/usr.bin/mandoc/mdoc/Ns/Makefile b/regress/usr.bin/mandoc/mdoc/Ns/Makefile
index 5117b56c9bc..45db66cc5eb 100644
--- a/regress/usr.bin/mandoc/mdoc/Ns/Makefile
+++ b/regress/usr.bin/mandoc/mdoc/Ns/Makefile
@@ -1,5 +1,6 @@
-# $OpenBSD: Makefile,v 1.4 2012/07/07 14:10:55 schwarze Exp $
+# $OpenBSD: Makefile,v 1.5 2014/07/02 11:42:56 schwarze Exp $
-REGRESS_TARGETS=position punct
+REGRESS_TARGETS = position punct
+LINT_TARGETS = position
.include <bsd.regress.mk>
diff --git a/regress/usr.bin/mandoc/mdoc/Ns/position.out_lint b/regress/usr.bin/mandoc/mdoc/Ns/position.out_lint
new file mode 100644
index 00000000000..d21bfe126f8
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Ns/position.out_lint
@@ -0,0 +1 @@
+mandoc: position.in:10:2: WARNING: skipping no-space macro
diff --git a/regress/usr.bin/mandoc/mdoc/Op/Makefile b/regress/usr.bin/mandoc/mdoc/Op/Makefile
index 85d9460933a..ab934a4e130 100644
--- a/regress/usr.bin/mandoc/mdoc/Op/Makefile
+++ b/regress/usr.bin/mandoc/mdoc/Op/Makefile
@@ -1,5 +1,9 @@
-# $OpenBSD: Makefile,v 1.2 2011/11/17 16:28:46 schwarze Exp $
+# $OpenBSD: Makefile,v 1.3 2014/07/02 11:42:56 schwarze Exp $
-REGRESS_TARGETS=punct
+REGRESS_TARGETS = break broken punct
+LINT_TARGETS = break broken
+
+SKIP_GROFF = break
+SKIP_ASCII = break
.include <bsd.regress.mk>
diff --git a/regress/usr.bin/mandoc/mdoc/Op/break.in b/regress/usr.bin/mandoc/mdoc/Op/break.in
new file mode 100644
index 00000000000..5ca7ffe28b1
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Op/break.in
@@ -0,0 +1,29 @@
+.Dd July 2, 2014
+.Dt OP-BREAK 1
+.Os OpenBSD
+.Sh NAME
+.Nm Op-break
+.Nd partial explicit block broken by partial implicit block
+.Sh DESCRIPTION
+before both
+.Op inside first Do inside both
+inside second
+.Dc
+after both
+.Pp
+0
+.Op 1 Op 12 Do 123
+3
+.Dc
+0
+.\" The following does not work yet:
+.ig
+.Pp
+0
+.Op 1 Op 12 Do 123 Do 1234
+34
+.Dc
+4
+.Dc
+0
+..
diff --git a/regress/usr.bin/mandoc/mdoc/Op/break.out_lint b/regress/usr.bin/mandoc/mdoc/Op/break.out_lint
new file mode 100644
index 00000000000..879b003ff94
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Op/break.out_lint
@@ -0,0 +1,3 @@
+mandoc: break.in:9:2: WARNING: blocks badly nested: Op breaks Do
+mandoc: break.in:15:7: WARNING: blocks badly nested: Op breaks Do
+mandoc: break.in:15:2: WARNING: blocks badly nested: Op breaks Op
diff --git a/regress/usr.bin/mandoc/mdoc/Op/broken.in b/regress/usr.bin/mandoc/mdoc/Op/broken.in
new file mode 100644
index 00000000000..43574317659
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Op/broken.in
@@ -0,0 +1,24 @@
+.Dd July 2, 2014
+.Dt OP-BROKEN 1
+.Os OpenBSD
+.Sh NAME
+.Nm Op-broken
+.Nd partial implicit block broken by partial explicit block
+.Sh DESCRIPTION
+before both
+.Do inside first
+.Op inside both Dc inside second
+after both
+.Pp
+0
+.Do 1
+.Op 12 Op 123 Dc 23
+0
+.\" The following does not work yet, see mdoc_macro.c rev. 1.47.
+.ig
+.Pp
+0
+.Do 1 Do 12
+.Op 123 Op 1234 Dc 134 Dc 34
+0
+..
diff --git a/regress/usr.bin/mandoc/mdoc/Op/broken.out_ascii b/regress/usr.bin/mandoc/mdoc/Op/broken.out_ascii
new file mode 100644
index 00000000000..32f1a6a1248
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Op/broken.out_ascii
@@ -0,0 +1,11 @@
+OP-BROKEN(1) OpenBSD Reference Manual OP-BROKEN(1)
+
+NNAAMMEE
+ OOpp--bbrrookkeenn - partial implicit block broken by partial explicit block
+
+DDEESSCCRRIIPPTTIIOONN
+ before both ``inside first [inside both'' inside second] after both
+
+ 0 ``1 [12 [123'' 23]] 0
+
+OpenBSD July 2, 2014 OpenBSD
diff --git a/regress/usr.bin/mandoc/mdoc/Op/broken.out_lint b/regress/usr.bin/mandoc/mdoc/Op/broken.out_lint
new file mode 100644
index 00000000000..dbab12976d0
--- /dev/null
+++ b/regress/usr.bin/mandoc/mdoc/Op/broken.out_lint
@@ -0,0 +1,2 @@
+mandoc: broken.in:10:17: WARNING: blocks badly nested: Dc breaks Op
+mandoc: broken.in:15:15: WARNING: blocks badly nested: Dc breaks Op