[PATCH] libstdc++: Add [[nodiscard]] to std::byteswap

Jonathan Wakely jwakely@redhat.com
Tue Nov 30 10:41:05 GMT 2021


On Tue, 30 Nov 2021 at 08:58, Jakub Jelinek via Libstdc++
<libstdc++@gcc.gnu.org> wrote:
>
> Hi!
>
> This patch adds [[nodiscard]] to std::byteswap, because the function
> template doesn't do anything useful if the result isn't used.
>
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?

Yes, thanks.



More information about the Gcc-patches mailing list