This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
fix fortran debug/9864
- From: Richard Henderson <rth at twiddle dot net>
- To: Toon Moene <toon at moene dot indiv dot nluug dot nl>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Thu, 12 Jun 2003 14:17:17 -0700
- Subject: fix fortran debug/9864
The problem to me appears to be that the FUNCTION_DECL for QUUS
winds up in a local binding level for BAZ, rather than at the
global binding level. The following appears to fix the problem.
I'm somewhat concerned about the assert at the beginning of
start_decl and finish_decl, but I couldn't trigger it. Toon,
would you mind running this across a larger set of Fortran
input and see if Something Bad Happens?
r~
* com.c (ffecom_sym_transform_): Install FFEINFO_whereGLOBAL
symbols in the global binding level.
Index: f/com.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/f/com.c,v
retrieving revision 1.202
diff -c -p -d -u -r1.202 com.c
--- f/com.c 8 Jun 2003 14:42:05 -0000 1.202
+++ f/com.c 12 Jun 2003 21:09:09 -0000
@@ -8078,8 +8078,8 @@ ffecom_sym_transform_ (ffesymbol s)
DECL_EXTERNAL (t) = 1;
TREE_PUBLIC (t) = 1;
- t = start_decl (t, FALSE);
- finish_decl (t, NULL_TREE, FALSE);
+ t = start_decl (t, TRUE);
+ finish_decl (t, NULL_TREE, TRUE);
if ((g != NULL)
&& ((ffeglobal_type (g) == FFEGLOBAL_typeSUBR)