C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Ignoring attributes (was: Floating an idea: [[no_address]] for functions)

From: Marcin Jaczewski <marcinjaczewski86_at_[hidden]>
Date: Mon, 24 Mar 2025 17:09:35 +0100
pon., 24 mar 2025 o 17:07 Jonathan Wakely via Std-Proposals
<std-proposals_at_[hidden]> napisaƂ(a):
>
>
>
> On Mon, 24 Mar 2025 at 15:56, Matheus Izvekov via Std-Proposals <std-proposals_at_[hidden]> wrote:
>>
>> I don't disagree in principle with the idea of allowing more kinds of
>> attributes, which currently ignorability rules out.
>>
>> But I think the status quo with vendor attributes is not very safe.
>> Either they should be mandatory to implement, or the compiler should
>> make it ill-formed
>> to use an attribute it doesn't know about, which seems would be quite
>> a breaking change.
>
>
> "ill-formed" only requires a diagnostic, which can be a warning. Most compilers already do that for unknown attributes, and have something like -Werror=attributes to make it a hard error.
>

how then support portable program that use GCC, Clang, MSVC, IC and maybe others
that need specific attributes form each compiler?

>
> --
> Std-Proposals mailing list
> Std-Proposals_at_[hidden]
> https://lists.isocpp.org/mailman/listinfo.cgi/std-proposals

Received on 2025-03-24 16:09:48