[Toybox] Warning: gcc can't tell this is never used uninitialized, but llvm can.

Josh Gao jmgao at google.com
Tue Oct 30 10:35:21 PDT 2018


On Tue, Oct 30, 2018 at 10:05 AM Rob Landley <rob at landley.net> wrote:

> On 10/30/18 11:40 AM, Rob Landley wrote:
> > And the three warnings gcc produces (but llvm doesn't), the larger todo
> item for
> > which is to figure out what to do about the "int x = x;" stuff,
>
> Ooh, spoke too soon. The gcc guys _did_ split it up so you can specifically
> disable this warning without losing the "is used uninitialized" one.
>
> (assuming current llvm doesn't barf on the extra flag)
>

I have bad news for you:
$ ./prebuilts/clang/host/linux-x86/clang-r339409b/bin/clang
-Wmaybe-initialized -x c++ -
warning: unknown warning option '-Wmaybe-initialized'; did you mean
'-Wuninitialized'? [-Wunknown-warning-option]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20181030/9bf05da2/attachment-0001.htm>


More information about the Toybox mailing list