This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
libstdc++/1070: incorrect specialization of std::complex<float>
- To: gcc-gnats at gcc dot gnu dot org
- Subject: libstdc++/1070: incorrect specialization of std::complex<float>
- From: fsm at robots dot ox dot ac dot uk
- Date: 15 Dec 2000 12:57:42 -0000
- Reply-To: fsm at robots dot ox dot ac dot uk
>Number: 1070
>Category: libstdc++
>Synopsis: incorrect specialization of std::complex<float>
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Dec 15 05:06:00 PST 2000
>Closed-Date:
>Last-Modified:
>Originator: Frederik Schaffalitzky
>Release: CVS checkout: gcc version 2.97 20001214 (experimental)
>Organization:
>Environment:
Linux shadow.robots.ox.ac.uk 2.2.17 #3 SMP Mon Nov 6 20:09:01 GMT 2000 i686 unknown
>Description:
In bits/std_complex.h, the explicit specialization for
one operator-= is wrong:
template<typename _Tp>
inline complex<float>&
complex<float>::operator-=(const complex<_Tp>& __z)
{
__real__ _M_value -= __z.real();
__imag__ _M_value -= __z.real(); // <--- here
return *this;
}
>How-To-Repeat:
>Fix:
replace second __z.real() with __z.imag()
>Release-Note:
>Audit-Trail:
>Unformatted: