+2015-01-06 Robert Dewar <dewar@adacore.com>
+
+ * ali-util.adb, sem_prag.adb, rtsfind.adb, sem_util.adb, sem_res.adb,
+ ali.adb, binde.adb, namet.adb, namet.ads, gnatls.adb, bcheck.adb:
+ Minor change of name Name_Table_Info => Name_Table_Int.
+
2015-01-06 Robert Dewar <dewar@adacore.com>
* exp_strm.adb (Build_Elementary_Input_Call): Clarify comments
-- --
-- B o d y --
-- --
--- Copyright (C) 1992-2013, Free Software Foundation, Inc. --
+-- Copyright (C) 1992-2014, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
-- This loop is empty and harmless the first time in.
for J in Source.First .. Source.Last loop
- Set_Name_Table_Info (Source.Table (J).Sfile, 0);
+ Set_Name_Table_Int (Source.Table (J).Sfile, 0);
Source.Table (J).Source_Found := False;
end loop;
-- file has not been processed already.
if Afile /= No_File
- and then Get_Name_Table_Info (Afile) = 0
+ and then Get_Name_Table_Int (Afile) = 0
then
Text := Read_Library_Info (Afile);
Error_Msg_File_1 := Afile;
Error_Msg_File_2 := Withs.Table (W).Sfile;
Error_Msg ("{ not found, { must be compiled");
- Set_Name_Table_Info (Afile, Int (No_Unit_Id));
+ Set_Name_Table_Int (Afile, Int (No_Unit_Id));
return;
end if;
then
Error_Msg_File_1 := Withs.Table (W).Sfile;
Error_Msg ("{ had errors, must be fixed, and recompiled");
- Set_Name_Table_Info (Afile, Int (No_Unit_Id));
+ Set_Name_Table_Int (Afile, Int (No_Unit_Id));
-- In GNATprove mode, object files are never generated, so
-- No_Object=True is not considered an error.
then
Error_Msg_File_1 := Withs.Table (W).Sfile;
Error_Msg ("{ must be recompiled");
- Set_Name_Table_Info (Afile, Int (No_Unit_Id));
+ Set_Name_Table_Int (Afile, Int (No_Unit_Id));
end if;
-- If the Unit is an Interface to a Stand-Alone Library,
-- If this is the first time we are seeing this source file,
-- then make a new entry in the source table.
- if Get_Name_Table_Info (F) = 0 then
+ if Get_Name_Table_Int (F) = 0 then
Source.Increment_Last;
S := Source.Last;
- Set_Name_Table_Info (F, Int (S));
+ Set_Name_Table_Int (F, Int (S));
Source.Table (S).Sfile := F;
Source.Table (S).All_Timestamps_Match := True;
-- so that the source table entry is already constructed.
else
- S := Source_Id (Get_Name_Table_Info (F));
+ S := Source_Id (Get_Name_Table_Int (F));
-- Update checksum flag
-- Set the checksum value in the source table
- S := Source_Id (Get_Name_Table_Info (F));
+ S := Source_Id (Get_Name_Table_Int (F));
Source.Table (S).Checksum := Sdep.Table (D).Checksum;
end if;
begin
for D in ALIs.Table (A).First_Sdep .. ALIs.Table (A).Last_Sdep loop
- Src := Source_Id (Get_Name_Table_Info (Sdep.Table (D).Sfile));
+ Src := Source_Id (Get_Name_Table_Int (Sdep.Table (D).Sfile));
if Opt.Minimal_Recompilation
and then Sdep.Table (D).Stamp /= Source.Table (Src).Stamp
-- These two loops are empty and harmless the first time in.
for J in ALIs.First .. ALIs.Last loop
- Set_Name_Table_Info (ALIs.Table (J).Afile, 0);
+ Set_Name_Table_Int (ALIs.Table (J).Afile, 0);
end loop;
for J in Units.First .. Units.Last loop
- Set_Name_Table_Info (Units.Table (J).Uname, 0);
+ Set_Name_Table_Int (Units.Table (J).Uname, 0);
end loop;
-- Free argument table strings
ALIs.Increment_Last;
Id := ALIs.Last;
- Set_Name_Table_Info (F, Int (Id));
+ Set_Name_Table_Int (F, Int (Id));
ALIs.Table (Id) := (
Afile => F,
-- Check for duplicated unit in different files
declare
- Info : constant Int := Get_Name_Table_Info
+ Info : constant Int := Get_Name_Table_Int
(Units.Table (Units.Last).Uname);
begin
if Info /= 0
end if;
end;
- Set_Name_Table_Info
+ Set_Name_Table_Int
(Units.Table (Units.Last).Uname, Int (Units.Last));
-- Scan out possible version and other parameters
goto Continue;
end if;
- Src := Source_Id (Get_Name_Table_Info (Sdep.Table (D).Sfile));
+ Src := Source_Id (Get_Name_Table_Int (Sdep.Table (D).Sfile));
-- If the time stamps match, or all checksums match, then we
-- are OK, otherwise we have a definite error.
WR : With_Record renames Withs.Table (W);
begin
- if Get_Name_Table_Info (WR.Uname) /= 0 then
+ if Get_Name_Table_Int (WR.Uname) /= 0 then
declare
WU : Unit_Record renames
Units.Table
(Unit_Id
- (Get_Name_Table_Info (WR.Uname)));
+ (Get_Name_Table_Int (WR.Uname)));
begin
-- Case 1. Elaborate_All for with'ed unit
if AFN /= No_File then
declare
WAI : constant ALI_Id :=
- ALI_Id (Get_Name_Table_Info (AFN));
+ ALI_Id (Get_Name_Table_Int (AFN));
WTE : ALIs_Record renames ALIs.Table (WAI);
begin
declare
Unit : constant Unit_Name_Type := Name_Find;
- Info : constant Int := Get_Name_Table_Info (Unit);
+ Info : constant Int := Get_Name_Table_Int (Unit);
begin
if Info /= 0 then
then
declare
Info : constant Int :=
- Get_Name_Table_Info (Withs.Table (W).Uname);
+ Get_Name_Table_Int (Withs.Table (W).Uname);
begin
-- If the unit is unknown, for some unknown reason, fail
-- when we have a subprogram body with no spec, and some
-- obsolete unit with's a previous (now disappeared) spec.
- if Get_Name_Table_Info (Withs.Table (W).Uname) = 0 then
+ if Get_Name_Table_Int (Withs.Table (W).Uname) = 0 then
Error_Msg_File_1 := Units.Table (U).Sfile;
Error_Msg_Unit_1 := Withs.Table (W).Uname;
Error_Msg ("{ depends on $ which no longer exists");
----------------
function Unit_Id_Of (Uname : Unit_Name_Type) return Unit_Id is
- Info : constant Int := Get_Name_Table_Info (Uname);
+ Info : constant Int := Get_Name_Table_Int (Uname);
begin
pragma Assert (Info /= 0 and then Unit_Id (Info) /= No_Unit_Id);
return Unit_Id (Info);
else
Ali_File := Strip_Directory (Ali_File);
- if Get_Name_Table_Info (Ali_File) = 0 then
+ if Get_Name_Table_Int (Ali_File) = 0 then
Text := Read_Library_Info (Ali_File, True);
declare
end Get_Name_Table_Byte;
-------------------------
- -- Get_Name_Table_Info --
+ -- Get_Name_Table_Int --
-------------------------
- function Get_Name_Table_Info (Id : Name_Id) return Int is
+ function Get_Name_Table_Int (Id : Name_Id) return Int is
begin
pragma Assert (Id in Name_Entries.First .. Name_Entries.Last);
return Name_Entries.Table (Id).Int_Info;
- end Get_Name_Table_Info;
+ end Get_Name_Table_Int;
-----------------------------------------
-- Get_Unqualified_Decoded_Name_String --
end Set_Name_Table_Byte;
-------------------------
- -- Set_Name_Table_Info --
+ -- Set_Name_Table_Int --
-------------------------
- procedure Set_Name_Table_Info (Id : Name_Id; Val : Int) is
+ procedure Set_Name_Table_Int (Id : Name_Id; Val : Int) is
begin
pragma Assert (Id in Name_Entries.First .. Name_Entries.Last);
Name_Entries.Table (Id).Int_Info := Val;
- end Set_Name_Table_Info;
+ end Set_Name_Table_Int;
-----------------------------
-- Store_Encoded_Character --
pragma Inline (Get_Name_Table_Byte);
-- Fetches the Byte value associated with the given name
- function Get_Name_Table_Info (Id : Name_Id) return Int;
- pragma Inline (Get_Name_Table_Info);
+ function Get_Name_Table_Int (Id : Name_Id) return Int;
+ pragma Inline (Get_Name_Table_Int);
-- Fetches the Int value associated with the given name
function Get_Name_Table_Boolean (Id : Name_Id) return Boolean;
-- in Name_Len (i.e. the characters of the name are in subscript positions
-- 1 to Name_Len in Name_Buffer). It searches the names table to see if the
-- string has already been stored. If so the Id of the existing entry is
- -- returned. Otherwise a new entry is created with its Name_Table_Info
+ -- returned. Otherwise a new entry is created with its Name_Table_Int
-- fields set to zero/false. The contents of Name_Buffer and Name_Len are
-- not modified by this call. Note that it is permissible for Name_Len to
-- be set to zero to lookup the null name string.
-- for the given character code. On return Name_Buffer and Name_Len are
-- set to reflect the stored name.
- procedure Set_Name_Table_Info (Id : Name_Id; Val : Int);
- pragma Inline (Set_Name_Table_Info);
+ procedure Set_Name_Table_Int (Id : Name_Id; Val : Int);
+ pragma Inline (Set_Name_Table_Int);
-- Sets the Int value associated with the given name
procedure Set_Name_Table_Byte (Id : Name_Id; Val : Byte);
RE_Str (RE_Str'First + 3 .. RE_Str'Last);
Nam := Name_Find;
- Ent := Entity_Id (Get_Name_Table_Info (Nam));
+ Ent := Entity_Id (Get_Name_Table_Int (Nam));
Name_Len := Save_Nam'Length;
Name_Buffer (1 .. Name_Len) := Save_Nam;
if Prag_Id = Pragma_Import then
String_To_Name_Buffer (Strval (Expr_Value_S (Ext_Nam)));
Nam := Name_Find;
- E := Entity_Id (Get_Name_Table_Info (Nam));
+ E := Entity_Id (Get_Name_Table_Int (Nam));
if Nam /= Chars (Subprogram_Def)
and then Present (E)
-----------------------
-- Second pass (top-down) type checking and overload resolution procedures
- -- Typ is the type required by context. These procedures propagate the type
- -- information recursively to the descendants of N. If the node is not
+ -- Typ is the type required by context. These procedures propagate the
+ -- type information recursively to the descendants of N. If the node is not
-- overloaded, its Etype is established in the first pass. If overloaded,
- -- the Resolve routines set the correct type. For arith. operators, the
+ -- the Resolve routines set the correct type. For arithmetic operators, the
-- Etype is the base type of the context.
-- Note that Resolve_Attribute is separated off in Sem_Attr
Typ : Entity_Id;
Op_Id : Entity_Id);
-- Inverse transformation: if an operator is given in functional notation,
- -- then after resolving the node, transform into an operator node, so
- -- that operands are resolved properly. Recall that predefined operators
- -- do not have a full signature and special resolution rules apply.
+ -- then after resolving the node, transform into an operator node, so that
+ -- operands are resolved properly. Recall that predefined operators do not
+ -- have a full signature and special resolution rules apply.
procedure Rewrite_Renamed_Operator
(N : Node_Id;
function Get_Name_Entity_Id (Id : Name_Id) return Entity_Id is
begin
- return Entity_Id (Get_Name_Table_Info (Id));
+ return Entity_Id (Get_Name_Table_Int (Id));
end Get_Name_Entity_Id;
------------------------------
procedure Set_Name_Entity_Id (Id : Name_Id; Val : Entity_Id) is
begin
- Set_Name_Table_Info (Id, Int (Val));
+ Set_Name_Table_Int (Id, Int (Val));
end Set_Name_Entity_Id;
---------------------