Ingo Schwarze wrote in <[email protected]>: |URL: | <https://savannah.gnu.org/bugs/?57485> | | Summary: [PATCH] accept any number of arguments for .Dd in |the groff_mdoc(7) macros | Project: GNU troff | Submitted by: schwarze | Submitted on: Thu 26 Dec 2019 02:46:37 PM UTC | Category: Macro - mdoc | Severity: 2 - Minor | Item Group: Incorrect behaviour | Status: None | Privacy: Public | Assigned to: schwarze | Open/Closed: Open | Discussion Lock: Any | Planned Release: None | | _______________________________________________________ | |Details: | |The .Dd macro behaved in a weird way: | - Without arguments, it printed the string "Epoch". | - With one, two, four, or more arguments, it ignored all arguments \ | and used |the current date instead. | - Only for exactly three arguments, it printed the arguments.
Not true. You have already added the Mdocdate thing, that has been you, no? |None of this made sense. Giving the date as "Epoch" is absurd, and \ It is as good as anything else while constructing a manual page draft. Once you are done with it, you can give it a real value. |printing |the current date is just misleading: why should a document be considered |up-to-date when the author did not even bother to state the date of \ |the last |change? I for one disagree with you. If the most likely automatized release script does not tag the manual, then for a user looking at the manual page it likely is the "current" version as of today. Of course it is as good as anything else, or no, not really. I like that much better than those crap release scripts which do only partial tagging. For example here on my box cc(1) gives "BSD June 20, 2014 BSD", whereas the thing really belongs to gcc(1), and that is "gcc-8.3.0 2019-02-22 GCC(1)". See how great that is. |Admittedly, the behaviour for 0 and 4 or more arguments already appeared |4.3BSD-Reno, and the behaviour for 2 or 3 arguments in 4.4BSD. But it was |already wrong even in those days: several manual pages in 4.4BSD gave .Dd a |single, quoted argument, e.g. .Dd "June 9, 1993": cap_mkdb(1), id(1), \ |sed(1), |err(3), getcap(3), sysctl(3), amd(8), disklabel(8), and others. | |Consequently, simply print all the arguments, no matter how many there are. I would not do that, you also loose an explicit unbreakable space. |This bug was found by Jonathan Gray <[email protected]> while he looked at |4.xBSD manual pages. I don't think so. Maybe there should be a warning that the macro is misued, if not used as documented. Then the remaining arguments could simply be printed, but i for one would then ignore the obviously false arguments. And hey -- you are the one which gives all the importance to details, or is my memory fooling me. But anyway, who am i, my roff clone is hanging for five years now, i hope i can find some time next year, and anyway i hope i live long enough to bring some life back to wonderful roff. Sigh. |Date: Thu 26 Dec 2019 02:46:37 PM UTC Name: mdoc-Dd.patch Size: 4KiB \ | By: |schwarze | |<http://savannah.gnu.org/bugs/download.php?file_id=48120> I would hope for that patch not being included as is, however. --steffen | |Der Kragenbaer, The moon bear, |der holt sich munter he cheerfully and one by one |einen nach dem anderen runter wa.ks himself off |(By Robert Gernhardt)
