public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "janus at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/52909] [F03] Procedure pointers not private to modules
Date: Mon, 09 Apr 2012 14:40:00 -0000	[thread overview]
Message-ID: <bug-52909-4-P86wlgnB5q@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-52909-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52909

janus at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|unassigned at gcc dot       |janus at gcc dot gnu.org
                   |gnu.org                     |

--- Comment #2 from janus at gcc dot gnu.org 2012-04-09 14:40:12 UTC ---
Preliminary patch, which makes the test case work:


Index: gcc/fortran/trans-decl.c
===================================================================
--- gcc/fortran/trans-decl.c    (revision 186243)
+++ gcc/fortran/trans-decl.c    (working copy)
@@ -1536,6 +1536,14 @@ get_proc_pointer_decl (gfc_symbol *sym)
              VAR_DECL, get_identifier (sym->name),
              build_pointer_type (gfc_get_function_type (sym)));

+  if (sym->module)
+    {
+      /* Do name mangling.  */
+      gfc_set_decl_assembler_name (decl, gfc_sym_mangled_identifier (sym));
+      if (sym->attr.use_assoc)
+    DECL_IGNORED_P (decl) = 1;
+    }
+  
   if ((sym->ns->proc_name
       && sym->ns->proc_name->backend_decl == current_function_decl)
       || sym->attr.contained)


  parent reply	other threads:[~2012-04-09 14:40 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-08 23:13 [Bug fortran/52909] New: " abenson at caltech dot edu
2012-04-08 23:36 ` [Bug fortran/52909] [F03] " janus at gcc dot gnu.org
2012-04-09 14:40 ` janus at gcc dot gnu.org [this message]
2012-12-10 23:18 ` janus at gcc dot gnu.org
2012-12-10 23:21 ` janus at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-52909-4-P86wlgnB5q@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).