From: Alejandro Colomar <alx@kernel.org>
To: "Michael Kerrisk (man7.org)" <mtk@man7.org>
Cc: linux-man <linux-man@vger.kernel.org>
Subject: Re: Mangled function prototypes (phantom arguments)
Date: Wed, 27 May 2026 19:58:28 +0200 [thread overview]
Message-ID: <ahcvtYzeadqmhk62@devuan> (raw)
In-Reply-To: <CAFs=pgYAfonz99yGyoS+h76v7YrfT8=f4yg6zQFqDPgm8XfsoQ@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1160 bytes --]
Hi Michael,
On 2026-05-27T18:46:06+0200, Michael Kerrisk (man7.org) wrote:
> Hello Alex,
>
> Thanks for responding.
>
> > > The problems have all resulted in prototypes adding a phantom first
> > > argument. See for example this prototype from read.2:
> > >
> > > ssize_t read(size_t count;
> > > int fd, void buf[count], size_t count);
> >
> > This is valid C (except for the array of void, but that's a separate
> > topic).
>
> As we see, I'm not keeping up with my C :-).
To be fair, this is a very little-known feature (even though it's a very
old one). I (and a few others) are trying to make it more well known,
as it's quite interesting.
>
> Is this a GNU extension? Or part of the standard? Or an upcoming part
> of the standard?
It is a very old GNU extension. For decades, almost nobody had been
interested in it (I've never seen it used in the wild). One or two
years ago, we started discussing it in the C Committee; several of us
want it to be standard. However, Clang is vetoing it.
Cheers,
Alex
>
> Thanks,
>
> Michael
--
<https://www.alejandro-colomar.es>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2026-05-27 17:58 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-27 12:14 Mangled function prototypes (phantom arguments) Michael Kerrisk (man7.org)
2026-05-27 13:47 ` Alejandro Colomar
2026-05-27 16:46 ` Michael Kerrisk (man7.org)
2026-05-27 17:58 ` Alejandro Colomar [this message]
2026-05-28 13:06 ` Michael Kerrisk (man7.org)
2026-05-28 14:25 ` Alejandro Colomar
2026-05-28 18:39 ` Carlos O'Donell
2026-05-28 21:24 ` Alejandro Colomar
2026-05-28 21:43 ` Mark Harris
2026-05-28 22:10 ` Alejandro Colomar
2026-05-28 22:11 ` Alejandro Colomar
2026-05-28 22:56 ` Alejandro Colomar
2026-05-28 23:22 ` Mark Harris
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=ahcvtYzeadqmhk62@devuan \
--to=alx@kernel.org \
--cc=linux-man@vger.kernel.org \
--cc=mtk@man7.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