From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15226 invoked by alias); 17 Nov 2008 00:02:58 -0000 Received: (qmail 1903 invoked by uid 48); 17 Nov 2008 00:01:33 -0000 Date: Mon, 17 Nov 2008 00:02:00 -0000 Message-ID: <20081117000133.1902.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/38152] ICE for procedure pointer assignment In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "burnus 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: 2008-11/txt/msg01356.txt.bz2 ------- Comment #3 from burnus at gcc dot gnu dot org 2008-11-17 00:01 ------- (In reply to comment #2) > > By the way, the following also fails: > The error is fixed by the following trivial patch: Janus, do you plan to submit it? * * * Regarding the ICE, the following patch seems to work; one probably still needs to take care of mangling of the name etc. Also there needs to be a check for use-/host- association (cf. a few lines down and in gfc_finish_var_decl), adding those flags unconditionally is surely wrong. --- trans-decl.c (revision 141928) +++ trans-decl.c (working copy) @@ -1021,2 +1021,7 @@ gfc_get_symbol_decl (gfc_symbol * sym) decl = gfc_get_extern_function_decl (sym); + if (sym->attr.proc_pointer) + { + TREE_PUBLIC (decl) = 1; + TREE_STATIC (decl) = 1; + } return decl; -- burnus at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |burnus at gcc dot gnu dot | |org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38152