From a7b3792787e6c527360c4c12a3bd01821ff30e0d Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Tue, 26 May 2015 12:39:16 +0200 Subject: [multiple changes] 2015-05-26 Bob Duff * einfo.adb, einfo.ads, sprint.adb, lib-xref.ads: Minor cleanup: Remove obsolete Entity_Kinds E_String_Type and E_String_Subtype. Update redundant assertions. 2015-05-26 Gary Dismukes * sem_util.adb, sem_util.ads, sem_ch13.adb: Minor typo fixes. From-SVN: r223680 --- gcc/ada/ChangeLog | 10 ++++++++++ gcc/ada/einfo.adb | 7 +++---- gcc/ada/einfo.ads | 5 ----- gcc/ada/lib-xref.ads | 8 +------- gcc/ada/sem_ch13.adb | 2 +- gcc/ada/sem_util.adb | 4 ++-- gcc/ada/sem_util.ads | 2 +- gcc/ada/sprint.adb | 6 +++--- 8 files changed, 21 insertions(+), 23 deletions(-) diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 85c143b..e1384ae 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,13 @@ +2015-05-26 Bob Duff + + * einfo.adb, einfo.ads, sprint.adb, lib-xref.ads: Minor cleanup: Remove + obsolete Entity_Kinds E_String_Type and E_String_Subtype. Update + redundant assertions. + +2015-05-26 Gary Dismukes + + * sem_util.adb, sem_util.ads, sem_ch13.adb: Minor typo fixes. + 2015-05-26 Doug Rupp * init.c [vxworks]: Refine previous checkin. diff --git a/gcc/ada/einfo.adb b/gcc/ada/einfo.adb index dd7e232..bf25bfb 100644 --- a/gcc/ada/einfo.adb +++ b/gcc/ada/einfo.adb @@ -874,7 +874,7 @@ package body Einfo is function Component_Type (Id : E) return E is begin - pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id)); + pragma Assert (Is_Array_Type (Id)); return Node20 (Implementation_Base_Type (Id)); end Component_Type; @@ -1323,7 +1323,7 @@ package body Einfo is function First_Index (Id : E) return N is begin - pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id)); + pragma Assert (Is_Array_Type (Id)); return Node17 (Id); end First_Index; @@ -4204,7 +4204,7 @@ package body Einfo is procedure Set_First_Index (Id : E; V : N) is begin - pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id)); + pragma Assert (Is_Array_Type (Id)); Set_Node17 (Id, V); end Set_First_Index; @@ -7368,7 +7368,6 @@ package body Einfo is E_Ordinary_Fixed_Point_Subtype | E_Decimal_Fixed_Point_Subtype | E_Array_Subtype | - E_String_Subtype | E_Record_Subtype | E_Private_Subtype | E_Record_Subtype_With_Private | diff --git a/gcc/ada/einfo.ads b/gcc/ada/einfo.ads index 845a83d..6ca5e5e 100644 --- a/gcc/ada/einfo.ads +++ b/gcc/ada/einfo.ads @@ -4729,11 +4729,6 @@ package Einfo is -- An array subtype, created by an explicit array subtype declaration, -- or the use of an anonymous array subtype. - E_String_Type, - E_String_Subtype, - -- These are obsolete and not used any more, they are retained to ease - -- transition in getting rid of these obsolete entries. - E_String_Literal_Subtype, -- A special string subtype, used only to describe the type of a string -- literal (will always be one dimensional, with literal bounds). diff --git a/gcc/ada/lib-xref.ads b/gcc/ada/lib-xref.ads index b82f4b8..c463fe9 100644 --- a/gcc/ada/lib-xref.ads +++ b/gcc/ada/lib-xref.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1998-2014, Free Software Foundation, Inc. -- +-- Copyright (C) 1998-2015, 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- -- @@ -508,12 +508,6 @@ package Lib.Xref is E_Variable => '*', E_Void => ' ', - -- These are dummy entries which can be removed when we finally get - -- rid of these obsolete entries once and for all. - - E_String_Type => ' ', - E_String_Subtype => ' ', - -- The following entities are not ones to which we gather the cross- -- references, since it does not make sense to do so (e.g. references to -- a package are to the spec, not the body) Indeed the occurrence of the diff --git a/gcc/ada/sem_ch13.adb b/gcc/ada/sem_ch13.adb index cc0248a..7abf871 100644 --- a/gcc/ada/sem_ch13.adb +++ b/gcc/ada/sem_ch13.adb @@ -8443,7 +8443,7 @@ package body Sem_Ch13 is and then Pragma_Name (Ritem) = Name_Predicate then -- Acquire arguments. The expression itself is copied for use - -- in the predicate function, to preserve the orignal version + -- in the predicate function, to preserve the original version -- for ASIS use. Arg1 := First (Pragma_Argument_Associations (Ritem)); diff --git a/gcc/ada/sem_util.adb b/gcc/ada/sem_util.adb index 563d02e..8ffcdf7 100644 --- a/gcc/ada/sem_util.adb +++ b/gcc/ada/sem_util.adb @@ -10960,7 +10960,7 @@ package body Sem_Util is P : Node_Id; begin - -- Simplest case : entity is a concurrent type and we are currently + -- Simplest case: entity is a concurrent type and we are currently -- inside the body. This will eventually be expanded into a -- call to Self (for tasks) or _object (for protected objects). @@ -10986,7 +10986,7 @@ package body Sem_Util is end loop; end if; - -- In any other context this is not a current occurence + -- In any other context this is not a current occurrence return False; end Is_Current_Instance; diff --git a/gcc/ada/sem_util.ads b/gcc/ada/sem_util.ads index 0262372..99f7e45 100644 --- a/gcc/ada/sem_util.ads +++ b/gcc/ada/sem_util.ads @@ -1240,7 +1240,7 @@ package Sem_Util is function Is_Current_Instance (N : Node_Id) return Boolean; -- Predicate is true if N legally denotes a type name within its own -- declaration. Prior to Ada 2012 this covered only synchronized type - -- declarations. In Ada2012 it also covers type and subtype declarations + -- declarations. In Ada 2012 it also covers type and subtype declarations -- with aspects: Invariant, Predicate, and Default_Initial_Condition. function Is_Declaration (N : Node_Id) return Boolean; diff --git a/gcc/ada/sprint.adb b/gcc/ada/sprint.adb index 9e3dca6..63a397d 100644 --- a/gcc/ada/sprint.adb +++ b/gcc/ada/sprint.adb @@ -4201,7 +4201,7 @@ package body Sprint is Write_Id (Directly_Designated_Type (Typ)); - -- Array types and string types + -- Array types when E_Array_Type => Write_Header; @@ -4230,10 +4230,10 @@ package body Sprint is Sprint_Node (X); Set_Sloc (X, Old_Sloc); - -- Array subtypes and string subtypes. + -- Array subtypes. -- Preserve Sloc of index subtypes, as above. - when E_Array_Subtype | E_String_Subtype => + when E_Array_Subtype => Write_Header (False); Write_Id (Etype (Typ)); Write_Str (" ("); -- cgit v1.1