Global variable Sem_Type.Headers, which is used in type resolution, was
initialized twice: by elaboration and by Init_Interp_Tables (called by
Gnat1drv).
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* fmap.ads (Reset_Tables): Remove outdated references to
GNSA/ASIS.
* sem_eval.ads (Initialize): Likewise.
* sem_type.adb (Headers): Remove initialization at elaboration.
* sem_type.ads (Init_Interp_Tables): Remove outdated reference
to gnatf.
* stringt.ads (Initialize): Fix style in comment.
diff --git a/gcc/ada/fmap.ads b/gcc/ada/fmap.ads
--- a/gcc/ada/fmap.ads
+++ b/gcc/ada/fmap.ads
@@ -68,10 +68,7 @@ package Fmap is
-- mapping file whose file name is File_Name.
procedure Reset_Tables;
- -- Initialize all the internal data structures. This procedure is used
- -- when several compilations are performed by the same process (by GNSA
- -- for ASIS, for example) to remove any existing mappings from a previous
- -- compilation.
+ -- Initialize all the internal data structures
procedure Add_Forbidden_File_Name (Name : File_Name_Type);
-- Indicate that a source file name is forbidden. This is used when there
diff --git a/gcc/ada/sem_eval.ads b/gcc/ada/sem_eval.ads
--- a/gcc/ada/sem_eval.ads
+++ b/gcc/ada/sem_eval.ads
@@ -556,8 +556,7 @@ package Sem_Eval is
-- messages must always point to the same location as the parent message.
procedure Initialize;
- -- Initializes the internal data structures. Must be called before each
- -- separate main program unit (e.g. in a GNSA/ASIS context).
+ -- Initializes the internal data structures
private
-- The Eval routines are all marked inline, since they are called once
diff --git a/gcc/ada/sem_type.adb b/gcc/ada/sem_type.adb
--- a/gcc/ada/sem_type.adb
+++ b/gcc/ada/sem_type.adb
@@ -97,7 +97,7 @@ package body Sem_Type is
Header_Size : constant Int := 2 ** 12;
No_Entry : constant Int := -1;
- Headers : array (0 .. Header_Size) of Int := (others => No_Entry);
+ Headers : array (0 .. Header_Size) of Int;
package Interp_Map is new Table.Table (
Table_Component_Type => Interp_Ref,
diff --git a/gcc/ada/sem_type.ads b/gcc/ada/sem_type.ads
--- a/gcc/ada/sem_type.ads
+++ b/gcc/ada/sem_type.ads
@@ -94,7 +94,7 @@ package Sem_Type is
-----------------
procedure Init_Interp_Tables;
- -- Invoked by gnatf when processing multiple files
+ -- Initialize data structures for overload resolution
procedure Collect_Interps (N : Node_Id);
-- Invoked when the name N has more than one visible interpretation. This
diff --git a/gcc/ada/stringt.ads b/gcc/ada/stringt.ads
--- a/gcc/ada/stringt.ads
+++ b/gcc/ada/stringt.ads
@@ -56,7 +56,7 @@ package Stringt is
--------------------------------------
procedure Initialize;
- -- Initializes the strings table for a new compilation.
+ -- Initializes the strings table for a new compilation
procedure Lock;
-- Lock internal tables before calling back end