aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/regress/roff/mc/args.in
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2022-04-28 16:21:09 +0000
committerIngo Schwarze <schwarze@openbsd.org>2022-04-28 16:21:09 +0000
commitb3dd815817ebf3e3bb6e95b8e8b9cc6ed2c64ff8 (patch)
treee720f598888796ac87c46979b54d4543ad1a3fad /regress/roff/mc/args.in
parent4739b39372b31b9276373673e199b90e33fb70a8 (diff)
downloadmandoc-b3dd815817ebf3e3bb6e95b8e8b9cc6ed2c64ff8.tar.gz
mandoc-b3dd815817ebf3e3bb6e95b8e8b9cc6ed2c64ff8.zip
The syntax of the roff(7) .mc request is quite special
and the roff_onearg() parsing function is too generic, so provide a dedicated parsing function instead. This fixes an assertion failure when an \o escape sequence is passed as the argument; the bug was found by tb@ using afl(1). It also makes mandoc output more similar to groff in various cases.
Diffstat (limited to 'regress/roff/mc/args.in')
-rw-r--r--regress/roff/mc/args.in29
1 files changed, 29 insertions, 0 deletions
diff --git a/regress/roff/mc/args.in b/regress/roff/mc/args.in
new file mode 100644
index 00000000..4e9b245f
--- /dev/null
+++ b/regress/roff/mc/args.in
@@ -0,0 +1,29 @@
+.\" $OpenBSD: args.in,v 1.1 2022/04/28 16:16:46 schwarze Exp $
+.TH MC-ARGS 1 "April 28, 2022"
+.SH NAME
+mc-args \- arguments to the .mc request
+.SH DESCRIPTION
+.ll 50n
+.nf
+initial text
+.mc |suffix
+ASCII character in the margin
+.mc \CXX
+invalid escape sequence
+.mc \!
+unsupported escape sequence
+.mc \a
+ignored escape sequence
+.mc \(ba
+special character in the margin
+.mc \[integral]
+special character represented as string
+.mc \fR
+font escape in the margin
+.mc \N'124'
+numbered character in the margin
+.mc \[u007C]suffix
+Unicode character in the margin
+.mc \o'o/'
+overstriking in the margin
+.ll