From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 680 invoked by alias); 3 Jun 2010 22:43:08 -0000 Received: (qmail 645 invoked by uid 48); 3 Jun 2010 22:42:56 -0000 Date: Thu, 03 Jun 2010 22:43:00 -0000 Message-ID: <20100603224256.644.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug c++/44409] explicit call of a defined copy constructor does not work In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "redi at gcc dot gnu dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-06/txt/msg00405.txt.bz2 ------- Comment #2 from redi at gcc dot gnu dot org 2010-06-03 22:42 ------- Yes, this is eligible for copy elision, see [class.copy] — when a temporary class object that has not been bound to a reference (12.2) would be copied/moved to a class object with the same cv-unqualified type, the copy/move operation can be omitted by constructing the temporary object directly into the target of the omitted copy/move -- redi at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44409