This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/11977] illegal "no matching function for call to Base::Base(const Derived<int>&)" compile error
- From: "nathan at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Aug 2003 15:34:09 -0000
- Subject: [Bug c++/11977] illegal "no matching function for call to Base::Base(const Derived<int>&)" compile error
- References: <20030819150805.11977.vassili_bourdo@softhome.net>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11977
nathan at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
------- Additional Comments From nathan at gcc dot gnu dot org 2003-08-19 15:34 -------
not a bug.
Derived<int> d1 = 1;//compile error here
intializes a temporary Derived<int> object [8.5/14], which is then
copy constructed into d1. the base-initializer there fails.
12.8 allows a compiler to elide that copy construction -- but it must
still exist and be accessible.