This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: missed uninitialised variable warning
- From: Gabriel Dos Reis <gdr at integrable-solutions dot net>
- To: dewar at gnat dot com (Robert Dewar)
- Cc: aoliva at redhat dot com, akpm at osdl dot org, gcc at gcc dot gnu dot org, guerby at acm dot org, matz at suse dot de, pinskia at physics dot uc dot edu
- Date: 04 Aug 2003 20:30:53 +0200
- Subject: Re: missed uninitialised variable warning
- Organization: Integrable Solutions
- References: <20030804182102.23AD2F2D7C@nile.gnat.com>
dewar@gnat.com (Robert Dewar) writes:
| > void *x = &x;
| >
| > This must work, and I don't see anything possibly dubious about it.
|
|
| Well I certainly find the formal semantics in the C++ standard tricky
| sometimes since it is not a standard that I am fully familiar with,
| but I am not sure I can deduce that this must always work from the
| formal semantics. But that may just be me :-)
The declarator "x" designates an object whose initial value is its own
address.
-- Gaby