2023-05-04 18:56:48

by Miguel Ojeda

[permalink] [raw]
Subject: Re: [PATCH] Compiler Attributes: Add __counted_by macro

On Thu, May 4, 2023 at 8:16 PM Kees Cook <[email protected]> wrote:
>
> + * Optional: future support coming in clang 17 and gcc 14

Should we just say:

Optional: only supported since clang >= 17
Optional: only supported since gcc >= 14

even if they are in the future? That way we avoid changing it later.
If somebody asks, you already say it it is in the future the commit
message, so it should be clear enough... :)

And if the compilers end up not supporting it on those versions for
some unexpected reason, well, we will need to fix the comment either
way.

(I can change it on my side if you prefer)

Thanks!

Cheers,
Miguel


2023-05-05 00:08:14

by Kees Cook

[permalink] [raw]
Subject: Re: [PATCH] Compiler Attributes: Add __counted_by macro

On May 4, 2023 11:27:32 AM PDT, Miguel Ojeda <[email protected]> wrote:
>On Thu, May 4, 2023 at 8:16 PM Kees Cook <[email protected]> wrote:
>>
>> + * Optional: future support coming in clang 17 and gcc 14
>
>Should we just say:
>
> Optional: only supported since clang >= 17
> Optional: only supported since gcc >= 14
>
>even if they are in the future? That way we avoid changing it later.
>If somebody asks, you already say it it is in the future the commit
>message, so it should be clear enough... :)
>
>And if the compilers end up not supporting it on those versions for
>some unexpected reason, well, we will need to fix the comment either
>way.

Yeah, fair point!

>
>(I can change it on my side if you prefer)

Sure, thanks! (But I'm happy to send a v2 if that's easier for you, too.)

-Kees



--
Kees Cook