re PR c++/43120 (Virtual inheritance with covariant return type confuses GCC)
authorJason Merrill <jason@redhat.com>
Fri, 9 Jul 2010 19:36:19 +0000 (15:36 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Fri, 9 Jul 2010 19:36:19 +0000 (15:36 -0400)
commit02dea3ffc6e0f26963db8255ea003d0ede0918cc
tree27b3670f92dc982f83cc34bdb5baecdb238472d7
parent59ee2304b00de03560aca9fdba6eb9ac08e0a7b8
re PR c++/43120 (Virtual inheritance with covariant return type confuses GCC)

PR c++/43120
* cp-tree.h (BV_LOST_PRIMARY): New macro.
* class.c (update_vtable_entry_for_fn): Fix covariant thunk logic.
Set BV_LOST_PRIMARY.
(build_vtbl_initializer): Check BV_LOST_PRIMARY.

From-SVN: r162008
gcc/cp/ChangeLog
gcc/cp/class.c
gcc/cp/cp-tree.h
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/abi/covariant1.C
gcc/testsuite/g++.dg/abi/covariant6.C [new file with mode: 0644]
gcc/testsuite/g++.dg/inherit/covariant17.C
gcc/testsuite/g++.dg/inherit/covariant7.C