Patchwork Fix PR debug/53704

login
register
mail settings
Submitter Eric Botcazou
Date June 22, 2012, 7:13 a.m.
Message ID <201206220913.58728.ebotcazou@adacore.com>
Download mbox | patch
Permalink /patch/166537/
State New
Headers show

Comments

Eric Botcazou - June 22, 2012, 7:13 a.m.
This fixes the PR by making the is_fortran predicate functional on Darwin too.

Bootstrapped/regtested on Darwin by Dominique (thanks!), pre-approved by Jakub 
and applied on the mainline.


2012-06-22  Eric Botcazou  <ebotcazou@adacore.com>

	PR debug/53704
	* dwarf2out.c (gen_compile_unit_die): Use DW_LANG_Fortran90 as language
	for GNU Fortran if in strict DWARF2 mode.

Patch

Index: dwarf2out.c
===================================================================
--- dwarf2out.c	(revision 188855)
+++ dwarf2out.c	(working copy)
@@ -18127,6 +18127,9 @@  gen_compile_unit_die (const char *filena
 	    language = DW_LANG_Go;
 	}
     }
+  /* Use a degraded Fortran setting in strict DWARF2 so is_fortran works.  */
+  else if (strcmp (language_string, "GNU Fortran") == 0)
+    language = DW_LANG_Fortran90;
 
   add_AT_unsigned (die, DW_AT_language, language);