]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Remove double initialization of interpretation tables
authorPiotr Trojanek <trojanek@adacore.com>
Mon, 7 Dec 2020 23:22:20 +0000 (00:22 +0100)
committerPierre-Marie de Rodat <derodat@adacore.com>
Wed, 28 Apr 2021 09:38:02 +0000 (05:38 -0400)
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.

gcc/ada/fmap.ads
gcc/ada/sem_eval.ads
gcc/ada/sem_type.adb
gcc/ada/sem_type.ads
gcc/ada/stringt.ads

index 862b8eab74fb2f8383a562d30da33af182924e98..aae32191499fdec2372b9ec4d930cc79219f90f6 100644 (file)
@@ -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
index 972cee646d7936d3c0ef9feeb85dbde2706fe915..3cbd43826802c1c17cf85804ff82330128d1b511 100644 (file)
@@ -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
index 8dbfa182923ffa9d26e58f18a6b064502b5bd269..8f636be9914f2e8fba42f8bfe2ad8b7ced81aeb1 100644 (file)
@@ -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,
index 4dea6e2076d01d48ec061549b33af42a25b3c96b..3177bd3882211981a5a12d1101cef77fc101d8bf 100644 (file)
@@ -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
index 77a794e03c4d5d67cca800a7f7e44456c7b656af..b85a590d59c5170e2a40d41cf92df951c6d1021c 100644 (file)
@@ -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