+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):
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
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
-- --
-- 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- --
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
-- --
-- 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- --
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
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;
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.
-----------------------
while Scop /= Standard_Standard loop
if Scop = Subp then
return True;
+ else
+ Scop := Scope (Scop);
end if;
-
- Scop := Scope (Scop);
end loop;
return False;
-- 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
-- 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)
-- --
-- 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- --
-- 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;