linux-man.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
To: Alejandro Colomar <colomar.6.4.3@gmail.com>
Cc: mtk.manpages@gmail.com, linux-man <linux-man@vger.kernel.org>,
	Florian Weimer <fweimer@redhat.com>,
	libbsd@lists.freedesktop.org
Subject: Re: [RFC v1] system_data_types.7: Draft (and links to it: <type>.3)
Date: Mon, 14 Sep 2020 12:37:57 +0200	[thread overview]
Message-ID: <23bfb4c9-9cab-8d1f-46a2-00932501b5b8@gmail.com> (raw)
In-Reply-To: <af73c477-c8a6-c03f-c6db-ab613b8d6d2f@gmail.com>

Hello Alex,

On 9/14/20 2:20 AM, Alejandro Colomar wrote:
>>From ffd8ea312527935cd86cc7ed1133a08d4e642b06 Mon Sep 17 00:00:00 2001
> From: Alejandro Colomar <colomar.6.4.3@gmail.com>
> Date: Mon, 14 Sep 2020 02:07:50 +0200
> Subject: [RFC] First draft for system_data_types.7 (and links to it:
>  <type>.3)
> 
> Hi Michael,
> 
> This is my first draft.
> 
> There are still TODO things:
> - Add types (obviously)
> - Write specific "Conforming to" versions
>   For now I just wrote POSIX, but I'll write the specific versions.

Good. I think that we can get away with just mentioning one each of
POSIX.1-200x and Cxx, with the latter starting at C99. I think C89 is
far enough back in time that we don't need to clutter the page with
it. Something like:

Conforming to: C99 and later; POSIX.1-2001 and later.


>   Should I write the latest one, the oldest one, or how?

See above.

>   For C versions I did the following:
> 	If the type has been there since C89, I wrote C89, C99.
> 	If the type is >= C99, I wrote C99.
> 	If the type is >= C11, I wrote C11.
> - Correctly highlight function names and similar (see timer_t)
>   For this first draft, I just want to show you the idea.  I'll add
>   italics and all that stuff later on.
> - Review "See also" (right now: all results of 'grep -rl <type>')
>   I put everything that came up with grep in the See also section.
>   Is it too much?  Any other references I should add?

I am ambivalent on the question of "is it too much?". Some of those
lists seem rather long. But the question of whether it is valuable to
mention *all* of the APIs is open: maybe it is; maybe it is not. Then
again, trying to be exhaustive, makes the lists fragile (new API
appears, but we forgot to add it to the list). And then if we
do not include all of the APIs, what are the criteria for
inclusion/exclusion?

I'm going to hold my finger in the wind, and say: lets restrict the
list to what seem like the most relevant APIs, where obviously that is
a somewhat subjective choice. You could include all the other APIs in
.\" comments, so we can see what's excluded, and this may trigger some
tweaking. So, for 'struct timespec' the list might be as simple as:

clock_gettime(2), clock_nanosleep(2), nanosleep(2)
timerfd_gettime(2), timer_gettime(2)

Note by the way, that that list is not a subset of your list.
Instead, I looked inside the pages that you listed to see which APIs
seemed "relevant".

I cannot think of other references that you should add.

You better include suseconds_t in the next draft :-).

I think it would be better not to split the types into separate lists.
Instead (and note the formatting) order by type name:

.TP
.BI "union " sigval
...
.TP
.I time_t
...
.TP
.I timer_t
...
.TP
.BI "struct " timespec
...
.TP
.BI "struct " timeval
...

Having seen how it looks with the header files, I'm going to suggest a
differnt approach. Let's put them on a separate line, something like:

Obtained by including: <abc.h> or <xyz.h>

> ---
>  man3/sigval.3            |   1 +
>  man3/time_t.3            |   1 +
>  man3/timer_t.3           |   1 +
>  man3/timespec.3          |   1 +
>  man3/timeval.3           |   1 +

It's an open question whether the links should be in section 3 or 
section 7. Do you have any thoughts on what's better?

Don't get wrapped up in including too many more types in the
yet, while we try to iron out the format.

Also, I'd like to see the types added incrementally (one or a few
at a time), so that it's easy to comment on each type, when needed.

Thanks,

Michael



-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/

  reply	other threads:[~2020-09-14 10:39 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-11 12:47 [IDEA] New pages for types: structs and typedfefs Alejandro Colomar
2020-09-12  6:33 ` Michael Kerrisk (man-pages)
2020-09-12  8:59   ` Alejandro Colomar
2020-09-12  9:26     ` Alejandro Colomar
2020-09-13 12:01     ` Michael Kerrisk (man-pages)
2020-09-13 12:53       ` Alejandro Colomar
2020-09-13 20:20         ` Michael Kerrisk (man-pages)
2020-09-13 21:29           ` Alejandro Colomar
2020-09-14  0:20             ` [RFC v1] system_data_types.7: Draft (and links to it: <type>.3) Alejandro Colomar
2020-09-14 10:37               ` Michael Kerrisk (man-pages) [this message]
2020-09-14 10:55                 ` Michael Kerrisk (man-pages)
2020-09-22 20:21             ` [IDEA] New pages for types: structs and typedfefs Michael Kerrisk (man-pages)
2020-09-22 20:38               ` Thorsten Glaser
2020-09-23  8:36                 ` Michael Kerrisk (man-pages)
2020-09-23 19:54                   ` Thorsten Glaser
2020-09-14  9:19       ` Jakub Wilk
2020-09-14  9:49         ` Alejandro Colomar
2020-09-18  2:16       ` Guillem Jover
2020-09-19  8:45         ` Michael Kerrisk (man-pages)
2020-09-14 10:22 ` Alejandro Colomar
2020-09-14 14:03   ` [RFC v2] system_data_types.7: Draft v2 Alejandro Colomar
2020-09-14 15:00     ` Michael Kerrisk (man-pages)
2020-09-14 15:52       ` Alejandro Colomar
2020-09-14 19:33         ` Michael Kerrisk (man-pages)
2020-09-15  0:47   ` [RFC v3] sigval.3, ssize_t.3, suseconds_t.3, time_t.3, timer_t.3, timespec.3, timeval.3, system_data_types.7: Document system types (draft v3) Alejandro Colomar
2020-09-15  6:22     ` Michael Kerrisk (man-pages)
2020-09-15 13:33   ` [RFC v4] system_data_types.7: Document sigval, ssize_t, suseconds_t, time_t, timer_t, timespec & timeval Alejandro Colomar
2020-09-15 21:30     ` Michael Kerrisk (man-pages)
2020-09-16  0:59       ` Thorsten Glaser
2020-09-16  8:03         ` Michael Kerrisk (man-pages)
2020-09-16 10:06           ` Andries E. Brouwer
2020-09-16 11:00             ` Michael Kerrisk (man-pages)
2020-09-16 10:52   ` [RFC v5] system_data_types.7: Document types: sigval, ssize_t, suseconds_t, time_t, timer_t, timespec, timeval Alejandro Colomar
2020-09-16 10:56     ` Alejandro Colomar
2020-09-16 11:01   ` [RFC v6] " Alejandro Colomar
2020-09-16 19:24     ` Michael Kerrisk (man-pages)
2020-09-16 19:51       ` Alejandro Colomar
2020-09-16 21:32         ` Thorsten Glaser
2020-09-17  9:23           ` Alejandro Colomar
2020-09-17 10:27         ` Michael Kerrisk (man-pages)
2020-09-17 10:42   ` [PATCH v7 0/8] Document system data types Alejandro Colomar
2020-09-17 21:05     ` Michael Kerrisk (man-pages)
2020-09-17 21:16       ` Alejandro Colomar
2020-09-17 10:42   ` [PATCH v7 1/8] system_data_types.7: Document types: sigval, ssize_t, suseconds_t, time_t, timer_t, timespec, timeval Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 2/8] sigval.3: Add link page Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 3/8] ssize_t.3: " Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 4/8] suseconds_t.3: " Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 5/8] time_t.3: " Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 6/8] timer_t.3: " Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 7/8] timespec.3: " Alejandro Colomar
2020-09-17 10:43   ` [PATCH v7 8/8] timeval.3: " Alejandro Colomar

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=23bfb4c9-9cab-8d1f-46a2-00932501b5b8@gmail.com \
    --to=mtk.manpages@gmail.com \
    --cc=colomar.6.4.3@gmail.com \
    --cc=fweimer@redhat.com \
    --cc=libbsd@lists.freedesktop.org \
    --cc=linux-man@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).