[Ada] Debug renaming variables are initialized with pragma Initialize_Scalars

Arnaud Charlet charlet@adacore.com
Fri Sep 28 10:01:00 GMT 2007


Tested on i686-linux, commited on trunk.

The special variables associated with renaming declarations that encode the
debugger name of the renaming should not be initialzed, but were in the
case where pragma Initialize_Scalars was in effect. These are now marked
as Is_Internal which has the effect of suppressing this initialization.

2007-09-26  Gary Dismukes  <dismukes@adacore.com>

	* exp_dbug.adb (Debug_Renaming_Declaration): Set Is_Internal on the
	debug variable so that it won't be initialized when pragma
	Initialize_Scalars is in effect.

-------------- next part --------------
Index: exp_dbug.adb
===================================================================
--- exp_dbug.adb	(revision 128777)
+++ exp_dbug.adb	(working copy)
@@ -466,6 +466,11 @@ package body Exp_Dbug is
 
       Set_Needs_Debug_Info (Obj);
 
+      --  Mark the object as internal so that it won't be initialized when
+      --  pragma Initialize_Scalars or Normalize_Scalars is in use.
+
+      Set_Is_Internal (Obj);
+
       return Res;
 
    --  If we get an exception, just figure it is a case that we cannot


More information about the Gcc-patches mailing list