------- Additional Comments From reichelt at gcc dot gnu dot org 2005-02-24 12:21 ------- Here's an even shorter testcase. It should return 0, but doesn't since GCC 3.3. If I remove A's constructor, we get the failure since GCC 3.0.
====================================================== int n=4; struct A { A() {} A& operator= (const A&) { --n; return *this; } }; struct B { A x[2][2]; }; int main() { B b; b = b; return n; } ====================================================== -- What |Removed |Added ---------------------------------------------------------------------------- Known to fail|3.3 3.3.5 3.4.3 4.0.0 |3.0 3.2.3 3.3 3.3.5 3.4.3 | |4.0.0 Known to work|2.95.3 3.0.4 3.2.3 |2.95.3 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20142