This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

A fix for gcc.dg/dwarf2-1.c


The re-declaration of `foo' within `bar' wasn't getting the IGNORED
flag set, so we ended up trying to generate debugging information for
it, and failed.  Ok to install?

Index: gcc/ChangeLog
from  Alexandre Oliva  <aoliva@cygnus.com>

	* c-decl.c (duplicate_decls): Copy DECL_IGNORED_P on function
	re-declaration in the same scope.

Index: gcc/c-decl.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/c-decl.c,v
retrieving revision 1.113
diff -u -r1.113 c-decl.c
--- gcc/c-decl.c	2000/05/24 09:08:42	1.113
+++ gcc/c-decl.c	2000/05/26 07:57:51
@@ -1952,6 +1952,7 @@
 	  DECL_ARGUMENTS (newdecl) = DECL_ARGUMENTS (olddecl);
 	  if (DECL_INLINE (newdecl))
 	    DECL_ABSTRACT_ORIGIN (newdecl) = DECL_ORIGIN (olddecl);
+	  DECL_IGNORED_P (newdecl) = DECL_IGNORED_P (olddecl);
 	}
     }
   if (different_binding_level)

-- 
Alexandre Oliva    Enjoy Guaranį, see http://www.ic.unicamp.br/~oliva/
Cygnus Solutions, a Red Hat company        aoliva@{redhat, cygnus}.com
Free Software Developer and Evangelist    CS PhD student at IC-Unicamp
oliva@{lsd.ic.unicamp.br, gnu.org}   Write to mailing lists, not to me

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]