diff options
-rw-r--r-- | gcc/ada/ChangeLog | 11 | ||||
-rw-r--r-- | gcc/ada/erroutc.adb | 2 | ||||
-rw-r--r-- | gcc/ada/erroutc.ads | 4 | ||||
-rw-r--r-- | gcc/ada/exp_pakd.adb | 6 | ||||
-rw-r--r-- | gcc/ada/prj-dect.adb | 9 | ||||
-rw-r--r-- | gcc/ada/prj.adb | 5 | ||||
-rw-r--r-- | gcc/ada/prj.ads | 20 | ||||
-rw-r--r-- | gcc/ada/sem_ch12.adb | 22 | ||||
-rw-r--r-- | gcc/ada/sem_elab.ads | 4 |
9 files changed, 54 insertions, 29 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 1ddf41c..7729446 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,5 +1,16 @@ 2014-05-21 Robert Dewar <dewar@adacore.com> + * prj.ads, sem_ch12.adb, prj.adb, exp_pakd.adb, + sem_elab.ads: Minor reformatting. + * erroutc.adb, erroutc.ads (Warning_Specifically_Suppressed): Make Tag + parameter optional. + +2014-05-21 Pascal Obry <obry@adacore.com> + + * prj-dect.adb: Allow package Install in aggregate project. + +2014-05-21 Robert Dewar <dewar@adacore.com> + * sem_ch13.adb (Analyze_Aspect_Specifications): Insert_Delayed_Pragma is now used for the case of Attach_Handler. * sem_prag.adb: Minor comment improvements. diff --git a/gcc/ada/erroutc.adb b/gcc/ada/erroutc.adb index e0fad22..7e5b4a0 100644 --- a/gcc/ada/erroutc.adb +++ b/gcc/ada/erroutc.adb @@ -1458,7 +1458,7 @@ package body Erroutc is function Warning_Specifically_Suppressed (Loc : Source_Ptr; Msg : String_Ptr; - Tag : String) return String_Id + Tag : String := "") return String_Id is begin -- Loop through specific warning suppression entries diff --git a/gcc/ada/erroutc.ads b/gcc/ada/erroutc.ads index 219238a..96ac676 100644 --- a/gcc/ada/erroutc.ads +++ b/gcc/ada/erroutc.ads @@ -557,13 +557,13 @@ package Erroutc is function Warning_Specifically_Suppressed (Loc : Source_Ptr; Msg : String_Ptr; - Tag : String) return String_Id; + Tag : String := "") return String_Id; -- Determines if given message to be posted at given location is suppressed -- by specific ON/OFF Warnings pragmas specifying this particular message. -- If the warning is not suppressed then No_String is returned, otherwise -- the corresponding warning string is returned (or the null string if no -- Warning argument was present in the pragma). Tag is the error message - -- tag for the message in question. + -- tag for the message in question or the null string if there is no tag. function Warning_Treated_As_Error (Msg : String) return Boolean; -- Returns True if the warning message Msg matches any of the strings diff --git a/gcc/ada/exp_pakd.adb b/gcc/ada/exp_pakd.adb index 19264cb..b3be664 100644 --- a/gcc/ada/exp_pakd.adb +++ b/gcc/ada/exp_pakd.adb @@ -6,7 +6,7 @@ -- -- -- 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- -- @@ -484,8 +484,8 @@ package body Exp_Pakd is Expr : Node_Id) return Node_Id; -- The packed array code does unchecked conversions which in some cases -- may involve non-discrete types with differing sizes. The semantics of - -- such conversions is potentially endian dependent, and the effect we - -- want here for such a conversion is to do the conversion in size as + -- such conversions is potentially endianness dependent, and the effect + -- we want here for such a conversion is to do the conversion in size as -- though numeric items are involved, and we extend or truncate on the -- left side. This happens naturally in the little-endian case, but in -- the big endian case we can get left justification, when what we want diff --git a/gcc/ada/prj-dect.adb b/gcc/ada/prj-dect.adb index 2ce0310..dafe882 100644 --- a/gcc/ada/prj-dect.adb +++ b/gcc/ada/prj-dect.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 2001-2013, Free Software Foundation, Inc. -- +-- Copyright (C) 2001-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- -- @@ -214,8 +214,11 @@ package body Prj.Dect is Project_Qualifier_Of (Project, In_Tree); Name : constant Name_Id := Name_Of (Current_Package, In_Tree); begin - if Qualif in Aggregate_Project - and then Name /= Snames.Name_Builder + if (Qualif = Aggregate and then Name /= Snames.Name_Builder) + or else + (Qualif = Aggregate_Library + and then Name /= Snames.Name_Builder + and then Name /= Snames.Name_Install) then Error_Msg_Name_1 := Name; Error_Msg diff --git a/gcc/ada/prj.adb b/gcc/ada/prj.adb index a50823e..808325e 100644 --- a/gcc/ada/prj.adb +++ b/gcc/ada/prj.adb @@ -906,6 +906,11 @@ package body Prj is type Empty_State is null record; No_State : Empty_State; + -- This is needed for the State parameter of procedure Look_For_Sources + -- below, because of the instantiation For_Imported_Projects of generic + -- procedure For_Every_Project_Imported. As procedure Look_For_Sources + -- does not modify parameter State, there is no need to give its type + -- more than one value. procedure Look_For_Sources (Proj : Project_Id; diff --git a/gcc/ada/prj.ads b/gcc/ada/prj.ads index d0af1a2..ce6e01e 100644 --- a/gcc/ada/prj.ads +++ b/gcc/ada/prj.ads @@ -1534,13 +1534,19 @@ package Prj is In_Imported_Only : Boolean := False; In_Extended_Only : Boolean := False; Base_Name : File_Name_Type; - Index : Int := 0) return Source_Ids; - -- Find all source files with the given name. - -- If In_Extended_Only is True, it will search in project and the project - -- it extends, but not in the imported projects. - -- Elsif In_Imported_Only is True, it will search in project and the - -- projects it imports, but not in the others or in aggregated projects. - -- Else it searches in the whole tree. + Index : Int := 0) return Source_Ids; + -- Find all source files with the given name: + -- + -- If In_Extended_Only is True, it will search in project and the project + -- it extends, but not in the imported projects. + -- + -- If Extended_Only is False, and In_Imported_Only is True, it will + -- search in project and the projects it imports, but not in the others + -- or in aggregated projects. + -- + -- If both Extended_Only and In_Imported_Only are False (the default) + -- then it searches the whole tree. + -- -- If Index is specified, this only search for sources with that index. ----------------------- diff --git a/gcc/ada/sem_ch12.adb b/gcc/ada/sem_ch12.adb index c7d1669..0874a03 100644 --- a/gcc/ada/sem_ch12.adb +++ b/gcc/ada/sem_ch12.adb @@ -8207,9 +8207,9 @@ package body Sem_Ch12 is while Scop /= Standard_Standard loop if Scop = Subp then return True; + else + Scop := Scope (Scop); end if; - - Scop := Scope (Scop); end loop; return False; @@ -8257,10 +8257,10 @@ package body Sem_Ch12 is -- the generic body appears textually later, and the generic body is -- also in the main unit. - -- If instance is nested within a subprogram, and the generic body is - -- not, the instance is delayed because the enclosing body is. If - -- instance and body are within the same scope, or the same sub- - -- program body, indicate explicitly that the instance is delayed. + -- If instance is nested within a subprogram, and the generic body + -- is not, the instance is delayed because the enclosing body is. If + -- instance and body are within the same scope, or the same subprogram + -- body, indicate explicitly that the instance is delayed. Must_Delay := (Gen_Unit = Act_Unit @@ -8308,14 +8308,14 @@ package body Sem_Ch12 is -- package Inst is new ... -- In this particular scenario, the freeze node for Inst must - -- be inserted in the same manner as that of Parent_Inst - + -- be inserted in the same manner as that of Parent_Inst, -- before the next source body or at the end of the declarative -- list (body not available). If body P did not exist and -- Parent_Inst was frozen after Inst, either by a body - -- following Inst or at the end of the declarative region, the - -- freeze node for Inst must be inserted after that of - -- Parent_Inst. This relation is established by comparing the - -- Slocs of Parent_Inst freeze node and Inst. + -- following Inst or at the end of the declarative region, + -- the freeze node for Inst must be inserted after that of + -- Parent_Inst. This relation is established by comparing + -- the Slocs of Parent_Inst freeze node and Inst. if List_Containing (Get_Package_Instantiation_Node (Par)) = List_Containing (N) diff --git a/gcc/ada/sem_elab.ads b/gcc/ada/sem_elab.ads index abae4dd..797e04a 100644 --- a/gcc/ada/sem_elab.ads +++ b/gcc/ada/sem_elab.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1997-2012, Free Software Foundation, Inc. -- +-- Copyright (C) 1997-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- -- @@ -158,7 +158,7 @@ package Sem_Elab is -- not be generated (see detailed description in body). procedure Check_Task_Activation (N : Node_Id); - -- at the point at which tasks are activated in a package body, check + -- Tt the point at which tasks are activated in a package body, check -- that the bodies of the tasks are elaborated. end Sem_Elab; |