bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: warnings from MacOS clang


From: arnold
Subject: Re: warnings from MacOS clang
Date: Fri, 28 May 2021 00:30:37 -0600
User-agent: Heirloom mailx 12.5 7/5/10

Paul Eggert <eggert@cs.ucla.edu> wrote:

> On 5/27/21 1:46 PM, Eric Blake wrote:
>
> > Yet another portable solution is:
> > 
> > static mbstate_t s1;
> > mbstate_t s = s1;
> > 
> > also with its own form of ugliness.
>
> I did that years ago, but compilers complained about it when I made s1 
> 'const', and I vaguely recall complaints even when it wasn't 'const' 
> ("What? You're declaring a static variable that is always zero and never 
> changes? That must be a bug!!").
>
> At this point I wouldn't worry about the older clang and gcc versions 
> that complain about {0} as an initializer. We can either let them die 
> off noisily, or use the appropriate -Wno-whatever option when using them 
> to compile.

I've decided to just not worry about it. It's impossible to compile
without warnings on every single C compiler in the world.

Thanks,

Arnold



reply via email to

[Prev in Thread] Current Thread [Next in Thread]