Re: __attribute__ to selectively disable -Wmaybe-uninitialized

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

 



* mark at yahoo via Gcc-help:

> The necessity to add many of these pragmas makes the code difficult to
> read. Is there a variable attribute that could be used instead, 
> something like:
> char	*buffer __attribute__((uninitialized));

In the past, this has been suggested as an official way to suppress the
warning:

  char *buffer = buffer;

See <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=36296#c3> for an
example.

It has the downside that it is almost certainly not valid C++ and
probably not valid C, either.

Thanks,
Florian
-- 
Red Hat GmbH, https://de.redhat.com/ , Registered seat: Grasbrunn,
Commercial register: Amtsgericht Muenchen, HRB 153243,
Managing Directors: Charles Cachera, Brian Klemm, Laurie Krebs, Michael O'Neill




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux