aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@adacore.com>2021-01-05 08:05:12 -0500
committerPierre-Marie de Rodat <derodat@adacore.com>2021-05-04 05:17:32 -0400
commit2d5e5d89add24b9f987646c83db4639c77132be2 (patch)
treef4c543ee3010f464cfc6fdc3019a98fa0aa79f1b /gcc
parent0a272ac33f4baa3f616718aa9168dded33cde21b (diff)
downloadgcc-2d5e5d89add24b9f987646c83db4639c77132be2.zip
gcc-2d5e5d89add24b9f987646c83db4639c77132be2.tar.gz
gcc-2d5e5d89add24b9f987646c83db4639c77132be2.tar.bz2
[Ada] Address some ??? comments
gcc/ada/ * cstand.adb, sprint.adb, switch-c.adb, xr_tabls.ads, xr_tabls.adb, xref_lib.adb: Address ??? comments.
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ada/cstand.adb8
-rw-r--r--gcc/ada/sprint.adb8
-rw-r--r--gcc/ada/switch-c.adb7
-rw-r--r--gcc/ada/xr_tabls.adb25
-rw-r--r--gcc/ada/xr_tabls.ads2
-rw-r--r--gcc/ada/xref_lib.adb2
6 files changed, 24 insertions, 28 deletions
diff --git a/gcc/ada/cstand.adb b/gcc/ada/cstand.adb
index 092e64a..d15708b 100644
--- a/gcc/ada/cstand.adb
+++ b/gcc/ada/cstand.adb
@@ -817,7 +817,7 @@ package body CStand is
B_Node := New_Node (N_Character_Literal, Stloc);
Set_Is_Static_Expression (B_Node);
- Set_Chars (B_Node, No_Name); -- ???
+ Set_Chars (B_Node, No_Name);
Set_Char_Literal_Value (B_Node, Uint_0);
Set_Entity (B_Node, Empty);
Set_Etype (B_Node, Standard_Wide_Character);
@@ -827,7 +827,7 @@ package body CStand is
B_Node := New_Node (N_Character_Literal, Stloc);
Set_Is_Static_Expression (B_Node);
- Set_Chars (B_Node, No_Name); -- ???
+ Set_Chars (B_Node, No_Name);
Set_Char_Literal_Value (B_Node, UI_From_Int (16#FFFF#));
Set_Entity (B_Node, Empty);
Set_Etype (B_Node, Standard_Wide_Character);
@@ -866,7 +866,7 @@ package body CStand is
B_Node := New_Node (N_Character_Literal, Stloc);
Set_Is_Static_Expression (B_Node);
- Set_Chars (B_Node, No_Name); -- ???
+ Set_Chars (B_Node, No_Name);
Set_Char_Literal_Value (B_Node, Uint_0);
Set_Entity (B_Node, Empty);
Set_Etype (B_Node, Standard_Wide_Wide_Character);
@@ -876,7 +876,7 @@ package body CStand is
B_Node := New_Node (N_Character_Literal, Stloc);
Set_Is_Static_Expression (B_Node);
- Set_Chars (B_Node, No_Name); -- ???
+ Set_Chars (B_Node, No_Name);
Set_Char_Literal_Value (B_Node, UI_From_Int (16#7FFF_FFFF#));
Set_Entity (B_Node, Empty);
Set_Etype (B_Node, Standard_Wide_Wide_Character);
diff --git a/gcc/ada/sprint.adb b/gcc/ada/sprint.adb
index 57132ae..213b631 100644
--- a/gcc/ada/sprint.adb
+++ b/gcc/ada/sprint.adb
@@ -3132,11 +3132,6 @@ package body Sprint is
Write_Char (';');
- -- Don't we want to print more detail???
-
- -- Doc of this extended syntax belongs in sinfo.ads and/or
- -- sprint.ads ???
-
when N_SCIL_Dispatch_Table_Tag_Init =>
Write_Indent_Str ("[N_SCIL_Dispatch_Table_Tag_Init]");
@@ -4578,7 +4573,8 @@ package body Sprint is
Write_Str (");");
end;
- -- For all other Itypes, print ??? (fill in later)
+ -- For all other Itypes, print a triple ? (fill in later
+ -- if needed).
when others =>
Write_Header (True);
diff --git a/gcc/ada/switch-c.adb b/gcc/ada/switch-c.adb
index b97e0d6..1e94ade 100644
--- a/gcc/ada/switch-c.adb
+++ b/gcc/ada/switch-c.adb
@@ -427,7 +427,7 @@ package body Switch.C is
-- The reason for this prohibition is that the rewriting of
-- Sloc values causes strange malfunctions in the tests of
-- whether units belong to the main source. This is really a
- -- bug, but too hard to fix for a marginal capability ???
+ -- bug, but too hard to fix for a marginal capability.
-- The proper fix is to completely redo -gnatD processing so
-- that the tree is not messed with, and instead a separate
@@ -1613,11 +1613,6 @@ package body Switch.C is
Ptr := Ptr + 1;
end if;
- -- We ignore '/' in switches, this is historical, still needed???
-
- when '/' =>
- Store_Switch := False;
-
-- Anything else is an error (illegal switch character)
when others =>
diff --git a/gcc/ada/xr_tabls.adb b/gcc/ada/xr_tabls.adb
index 6d00201..a4c52d0 100644
--- a/gcc/ada/xr_tabls.adb
+++ b/gcc/ada/xr_tabls.adb
@@ -106,10 +106,16 @@ package body Xr_Tabls is
-- when sorting the table.
Longest_File_Name_In_Table : Natural := 0;
- Unvisited_Files : Unvisited_Files_Access := null;
- Directories : Project_File_Ptr;
- Default_Match : Boolean := False;
- -- The above need commenting ???
+ -- The length of the longest file name stored
+
+ Unvisited_Files : Unvisited_Files_Access := null;
+ -- Linked list of unvisited files
+
+ Directories : Project_File_Ptr;
+ -- Store the list of directories to visit
+
+ Default_Match : Boolean := False;
+ -- Default value for match in declarations
function Parse_Gnatls_Src return String;
-- Return the standard source directories (taking into account the
@@ -482,9 +488,8 @@ package body Xr_Tabls is
-------------------
function ALI_File_Name (Ada_File_Name : String) return String is
-
- -- ??? Should ideally be based on the naming scheme defined in
- -- project files.
+ -- Should ideally be based on the naming scheme defined in
+ -- project files but this is too late for an obsolescent feature.
Index : constant Natural :=
Ada.Strings.Fixed.Index
@@ -762,7 +767,7 @@ package body Xr_Tabls is
Strip : Natural := 0) return String
is
pragma Annotate (CodePeer, Skip_Analysis);
- -- ??? To disable false positives currently generated
+ -- Disable CodePeer false positives
Tmp : GNAT.OS_Lib.String_Access;
@@ -1385,8 +1390,8 @@ package body Xr_Tabls is
begin
File_Ref.Visited := False;
- -- ??? Do not add a source file to the list. This is true at
- -- least for gnatxref, and probably for gnatfind as well
+ -- Do not add a source file to the list. This is true for gnatxref
+ -- gnatfind, so good enough.
if F'Length > 4
and then F (F'Last - 3 .. F'Last) = "." & Osint.ALI_Suffix.all
diff --git a/gcc/ada/xr_tabls.ads b/gcc/ada/xr_tabls.ads
index b290afb..2f4dea0 100644
--- a/gcc/ada/xr_tabls.ads
+++ b/gcc/ada/xr_tabls.ads
@@ -23,7 +23,7 @@
-- --
------------------------------------------------------------------------------
--- We need comment here saying what this package is???
+-- Cross reference utilities used by gnatxref and gnatfind
with GNAT.OS_Lib;
diff --git a/gcc/ada/xref_lib.adb b/gcc/ada/xref_lib.adb
index 1f667cb..9a584a4 100644
--- a/gcc/ada/xref_lib.adb
+++ b/gcc/ada/xref_lib.adb
@@ -786,7 +786,7 @@ package body Xref_Lib is
-- line and column in the dependent unit number Eun. For this we need
-- to parse the ali file again because the parent entity is not in
-- the declaration table if it did not match the search pattern.
- -- If the symbol is not found, we return "???".
+ -- If the symbol is not found, we return (1 .. 3 => '?').
procedure Skip_To_Matching_Closing_Bracket;
-- When Ptr points to an opening square bracket, moves it to the