This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/20458] [4.1 regression] structure aliasing causes wrong code
- From: "belyshev at depni dot sinp dot msu dot ru" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 13 Mar 2005 19:10:24 -0000
- Subject: [Bug tree-optimization/20458] [4.1 regression] structure aliasing causes wrong code
- References: <20050313170208.20458.belyshev@depni.sinp.msu.ru>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From belyshev at depni dot sinp dot msu dot ru 2005-03-13 19:10 -------
even smaller testcase:
------------------------------------------------------------------------------
namespace std
{
class locale
{
public:
locale();
~locale();
};
}
struct B
{
std::locale _M_buf_locale;
virtual ~B() {}
};
struct C : public B
{
char *s;
};
void foo ()
{
C c;
}
int main()
{
foo ();
return 0;
}
------------------------------------------------------------------------------
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20458