source@mandoc.bsd.lv
 help / color / mirror / Atom feed
* mandoc: Use the MDOC_JOIN feature for .Ft, too.
@ 2025-06-13 14:25 schwarze
  0 siblings, 0 replies; only message in thread
From: schwarze @ 2025-06-13 14:25 UTC (permalink / raw)
  To: source

Log Message:
-----------
Use the MDOC_JOIN feature for .Ft, too.
Semantically, this makes sense because printing two function return types
one right after the other with nothing in between is never useful, whereas
function return types consisting of more than one word are widespread.
The change matters because people usually do not quote multi-word function
return types (nor should they).  We have about 1800 unquoted instances in
our tree versus about 300 quoted instances.

No output change intended, not even with respect to line breaking.
The regression suite remains happy, and this helps apropos(1)
searching for function return types that contain more than one word.
For example, this improves the command: man -k 'Ft=const EC_METHOD'
which (after makewhatis(8)) no longer misses the EC_GFp_simple_method(3)
manual page.

Modified Files:
--------------
    mandoc:
        mdoc_macro.c

Revision Data
-------------
Index: mdoc_macro.c
===================================================================
RCS file: /home/cvs/mandoc/mandoc/mdoc_macro.c,v
diff -Lmdoc_macro.c -Lmdoc_macro.c -u -p -r1.236 -r1.237
--- mdoc_macro.c
+++ mdoc_macro.c
@@ -92,7 +92,7 @@ static const struct mdoc_macro mdoc_macr
 	{ in_line_eoln, 0 }, /* Fd */
 	{ in_line, MDOC_CALLABLE | MDOC_PARSED }, /* Fl */
 	{ in_line, MDOC_CALLABLE | MDOC_PARSED }, /* Fn */
-	{ in_line, MDOC_CALLABLE | MDOC_PARSED }, /* Ft */
+	{ in_line, MDOC_CALLABLE | MDOC_PARSED | MDOC_JOIN }, /* Ft */
 	{ in_line, MDOC_CALLABLE | MDOC_PARSED | MDOC_JOIN }, /* Ic */
 	{ in_line_argn, MDOC_CALLABLE | MDOC_PARSED }, /* In */
 	{ in_line, MDOC_CALLABLE | MDOC_PARSED | MDOC_JOIN }, /* Li */
--
 To unsubscribe send an email to source+unsubscribe@mandoc.bsd.lv


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-06-13 14:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-06-13 14:25 mandoc: Use the MDOC_JOIN feature for .Ft, too schwarze

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).