This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/13387] [3.3/3.4 regression] assignment to base class corrupts subclass
- From: "cvs-commit 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 Dec 2003 10:08:54 -0000
- Subject: [Bug c++/13387] [3.3/3.4 regression] assignment to base class corrupts subclass
- References: <20031212022354.13387.Tasso.Karkanis@rogers.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2003-12-16 10:08 -------
Subject: Bug 13387
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: nathan@gcc.gnu.org 2003-12-16 10:08:43
Modified files:
gcc/cp : ChangeLog call.c cp-lang.c class.c
gcc/testsuite : ChangeLog
Added files:
gcc/testsuite/g++.dg/expr: assign1.C
Log message:
cp:
PR c++/13387
* class.c (finish_struct_1): Compute mode and alias set for
CLASSTYPE_AS_BASE.
* call.c (build_over_call): Use CLASSTYPE_AS_BASE for trivial
assignment of a class, as necessary.
* cp-lang.c (cxx_get_alias_set): The alias set as a base is the
same as for the complete type.
testsuite:
PR c++/13387
* g++.dg/expr/assign1.C: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.3809&r2=1.3810
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/call.c.diff?cvsroot=gcc&r1=1.444&r2=1.445
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/cp-lang.c.diff?cvsroot=gcc&r1=1.67&r2=1.68
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/class.c.diff?cvsroot=gcc&r1=1.588&r2=1.589
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.3266&r2=1.3267
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/expr/assign1.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13387