This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/23497] [4.1 regression] Bogus 'is used uninitialized...' warning about std::complex<T>
- From: "gdr at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Nov 2005 18:47:17 -0000
- Subject: [Bug middle-end/23497] [4.1 regression] Bogus 'is used uninitialized...' warning about std::complex<T>
- References: <bug-23497-2589@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #28 from gdr at gcc dot gnu dot org 2005-11-16 18:47 -------
(In reply to comment #25)
> Subject: Re: [4.1 regression] Bogus 'is used uninitialized...'
> warning about std::complex<T>
>
> schwab at suse dot de wrote:
> > ------- Comment #23 from schwab at suse dot de 2005-11-16 14:20 -------
> > (In reply to comment #22)
> >
> >>Note I never said __imag__ a should not act like an lvalue. I just said that
> >>__imag__ a = b; acts like a = COMPLEX<REAL<a>, b> which is just like what
> >>a = (a&0xFFFF0000)|(b&0x0000FFFF) does.
>
> If the compiler wants to implement it that way, that's OK.
>
> What's not OK is to warn about the fact that the real part is
> uninitialized. There is no user out there anywhere that wants to be
> warned about this case; it is in fact valid code.
We're in violent agree on the diagnostic issue.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23497