From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16042 invoked by alias); 3 Dec 2001 18:41:49 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 15982 invoked from network); 3 Dec 2001 18:41:40 -0000 Received: from unknown (HELO localhost.localdomain) (62.30.164.150) by sources.redhat.com with SMTP; 3 Dec 2001 18:41:40 -0000 Received: (from jason@localhost) by localhost.localdomain (8.11.6/8.11.6) id fB3Icph06749; Mon, 3 Dec 2001 18:38:51 GMT X-Authentication-Warning: localhost.localdomain: jason set sender to jason@redhat.com using -f To: "John David Anglin" Cc: gcc-patches@gcc.gnu.org, mark@codesourcery.com Subject: Re: C++ pcc struct return fix References: <200112031640.fB3Ge8YS027655@hiauly1.hia.nrc.ca> From: Jason Merrill In-Reply-To: <200112031640.fB3Ge8YS027655@hiauly1.hia.nrc.ca> ("John David Anglin"'s message of "Mon, 3 Dec 2001 11:40:08 -0500 (EST)") Date: Mon, 03 Dec 2001 10:41:00 -0000 Message-ID: User-Agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.1 (i686-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2001-12/txt/msg00189.txt.bz2 >>>>> "John" == John David Anglin writes: >> >>>>> "John" == John David Anglin writes: >> >> > * semantics.c (simplify_aggr_init_exprs_r): Add DIRECT_BIND flag in >> > call to build_aggr_init. >> >> DIRECT_BIND is for binding temporaries to reference variables; I'm not sure >> why this would have any effect on your problem. Perhaps rather than call >> build_aggr_init here, we should be doing an explicit constructor call as in >> ocp_convert. > It is a while since I looked at this problem but roughly what happens is > that build_aggr_init calls ocp_convert which calls simplify_aggr_init_exprs_r > which calls build_aggr_init which calls ... Look at expand_default_init. > I think this is why DIRECT_BIND has an affect. OK, it looks like initialize_handler_parm is already using DIRECT_BIND this way, so it's just a documentation issue. This patch is OK for trunk and branch; please also adjust the comment about DIRECT_BIND in cp-tree.h to reflect this usage. Jason