public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Schwarze <schwarze@usta.de>
To: Alejandro Colomar <alx.manpages@gmail.com>
Cc: linux-man@vger.kernel.org, groff@gnu.org,
	g.branden.robinson@gmail.com,
	Ralph Corderoy <ralph@inputplus.co.uk>
Subject: Re: [PATCH v3] NULL.3const: Add documentation for NULL
Date: Wed, 27 Jul 2022 12:49:40 +0200	[thread overview]
Message-ID: <YuEYRGc1/KBiIfuw@asta-kit.de> (raw)
In-Reply-To: <7368e5aa-4f26-4623-9f29-7564ff36fde5@gmail.com>

Hi Alejandro,

Alejandro Colomar wrote on Tue, Jul 26, 2022 at 02:02:56PM +0200:
> On 7/25/22 20:49, Ingo Schwarze wrote:
>> Alejandro Colomar wrote on Sun, Jul 24, 2022 at 09:19:32PM +0200:

>>> +.B 0

>> There is really no need to mark up integer constants.

> groff_man_style(7):
>                Use  bold for literal portions of syntax synopses,
>                for command‐line options in running text, and  for
>                literals  that are major topics of the subject un‐
>                der discussion; for example, this page  uses  bold
>                for  macro,  string,  and  register  names.  In an
>                .EX/.EE example of  interactive  I/O  (such  as  a
>                shell session), set only user input in bold.
> 
> Since this is a literal that is a major topic of the subject under 
> discussion, I prefer to be a bit pedantic here and boldface it.
> 
> I guess it's no big issue; does it hurt readability too much for you?

No, it's no big deal and doesn't hurt readability.  It only looks
slightly unusual.

There are cases where a bare '0' character needs to be bold face,
for example when discussing ".Fl 0" in xargs(1).  But here, you
are just talking about the integer 0.  The "major topic" here
is ".Dv NULL", not the ordinary integer 0 that is internally used
to define that constant.
Bold face is mostly for literals that the user needs to type -
and the user is specifically *not* supposed to type this 0.

That's why i consider the .B pointless; then again, it does not
do much harm either.


>>> +.SH CONFORMING TO

>> That should be ".SH STANDARDS".

> We use CONFORMING TO in Linux.  Don't know why; just history, I guess.
> See man-pages(7).

Weird.

I failed to find a single instance of "CONFORMING TO" in AT&T UNIX
(including v6, PWB, v7, 32v, v8, v10, System III, SVR1, SVR2) nor in
any version of UCB CSRG BSD.  So considering that System V and BSD are
widely considered the two main original branches of the development
of Unix-like operating systems and Linux is often considered to have
drawn inspiration from both, the section name "CONFORMING TO" does
not appear to be a UNIX thing.  For example, Aeleen Frisch, "Essential
System Administration", O'Reilly, Cambridge 1995, considers Linux
as slightly more influenced by 4.3BSD than by System V Release 3.

STANDARDS, on the other hand, is present since 4.3BSD-Reno (June 1990).

4.3BSD-Reno predates the first version of the Linux kernel by more than
a year, and the first Linux manual pages probably for longer than that.

So i have no idea where "CONFORMING TO" may have come from.


[...]
>>> +.SH BUGS

>> The following is misplaced in BUGS.  It is not talking about any bug,
>> nor about any API design defect.

> Oh, I do consider this a bug in the API design.  I placed it there on 
> purpose.
> 
> Allowing the bit pattern of all 0s to represent a valid pointer (and 
> thus not a null pointer) is something that could be meaningful many 
> decades ago, when architectures were more different.
> 
> Nowadays, every arch out there is 2's complement, and uses 0s as the 
> null pointer.  The standard should simplify, and allow memset(2)ing 
> pointers.
> 
> In fact, AFAIK, the next revision of POSIX will fix that bug.  But I 
> don't remember well the details of that.

Fair points.  You convinced me this isn't misplaced in BUGS.

Yours,
  Ingo

  reply	other threads:[~2022-07-27 10:49 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-22 15:31 [PATCH] NULL.3def: Add documentation for NULL Alejandro Colomar
2022-07-23 10:23 ` Ralph Corderoy
2022-07-24 12:49   ` Alejandro Colomar (man-pages)
2022-07-24 18:36 ` [PATCH] NULL.3const: " Alejandro Colomar
2022-07-24 19:19 ` [PATCH v3] " Alejandro Colomar
2022-07-25 18:49   ` Ingo Schwarze
2022-07-26 12:02     ` Alejandro Colomar
2022-07-27 10:49       ` Ingo Schwarze [this message]
2022-07-27 13:11         ` Alejandro Colomar
2022-07-28 23:28           ` Alejandro Colomar
2022-07-25 18:57   ` Jakub Wilk
2022-07-26 12:36     ` Alejandro Colomar
2022-07-26 12:48   ` [PATCH v4] " Alejandro Colomar
2022-07-26 15:54     ` G. Branden Robinson
2022-07-26 18:47       ` Alejandro Colomar
2022-07-27  9:50         ` Ingo Schwarze

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YuEYRGc1/KBiIfuw@asta-kit.de \
    --to=schwarze@usta.de \
    --cc=alx.manpages@gmail.com \
    --cc=g.branden.robinson@gmail.com \
    --cc=groff@gnu.org \
    --cc=linux-man@vger.kernel.org \
    --cc=ralph@inputplus.co.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox