Re: [PATCH 1/2] Compiler Attributes: add support for __fallthrough (gcc >= 7.1)
From: Miguel Ojeda
Date: Mon Oct 22 2018 - 07:24:20 EST
On Mon, Oct 22, 2018 at 12:53 PM Kees Cook <keescook@xxxxxxxxxxxx> wrote:
>
> On Mon, Oct 22, 2018 at 2:41 AM, Miguel Ojeda
> <miguel.ojeda.sandonis@xxxxxxxxx> wrote:
> > Please take a look at the rationale (also more details at the linked thread):
> >
> > * gcc 7.1 added -Wimplicit-fallthrough at the same time as the
> > attribute and the comment parsing.
>
> Ah, perfect. I missed this. :)
No problem! I know the commit message is a bit too long, so I understand :)
>
> > * clang does *not* support the attribute in C.
>
> Well that's not good. :)
I will see with clang if they plan to add it.
(By the way, if the "*not*" sounded rude, sorry; I wanted to emphasize
it is surprising that it doesn't -- I also assumed the opposite until
I checked it).
Cheers,
Miguel