Commit cd20e505 by Arnaud Charlet

[multiple changes]

2012-07-12  Robert Dewar  <dewar@adacore.com>

	* make.adb, sem_ch9.adb, prj.adb, s-rident.ads, snames.ads-tmpl: Minor
	reformatting.

2012-07-12  Javier Miranda  <miranda@adacore.com>

	* exp_ch3.adb (Is_User_Defined_Equality): New subprogram.
	(Make_Neq_Body): New subprogram.
	(Make_Predefined_Primitive_Specs): Adding local variable
	Has_Predef_Eq_ Renaming to ensure that we enable the machinery
	which handles renamings of predefined primitive operators.

From-SVN: r189432
parent 381ec0f4
2012-07-12 Robert Dewar <dewar@adacore.com>
* make.adb, sem_ch9.adb, prj.adb, s-rident.ads, snames.ads-tmpl: Minor
reformatting.
2012-07-12 Javier Miranda <miranda@adacore.com>
* exp_ch3.adb (Is_User_Defined_Equality): New subprogram.
(Make_Neq_Body): New subprogram.
(Make_Predefined_Primitive_Specs): Adding local variable
Has_Predef_Eq_ Renaming to ensure that we enable the machinery
which handles renamings of predefined primitive operators.
2012-07-09 Pascal Obry <obry@adacore.com> 2012-07-09 Pascal Obry <obry@adacore.com>
* prj.adb (For_Every_Project_Imported_Context): Make sure we * prj.adb (For_Every_Project_Imported_Context): Make sure we
......
...@@ -4807,8 +4807,10 @@ package body Make is ...@@ -4807,8 +4807,10 @@ package body Make is
return; return;
end if; end if;
-- Regenerate libraries, if there are any and if object files -- Regenerate libraries, if there are any and if object files have been
-- have been regenerated. -- regenerated. Note that we skip this in CodePeer mode because we don't
-- need libraries in this case, and more importantly, the object files
-- may not be present.
if Main_Project /= No_Project if Main_Project /= No_Project
and then not CodePeer_Mode and then not CodePeer_Mode
......
...@@ -599,12 +599,14 @@ package body Prj is ...@@ -599,12 +599,14 @@ package body Prj is
function Has_Sources (P : Project_Id) return Boolean is function Has_Sources (P : Project_Id) return Boolean is
Lang : Language_Ptr; Lang : Language_Ptr;
begin begin
Lang := P.Languages; Lang := P.Languages;
while Lang /= No_Language_Index loop while Lang /= No_Language_Index loop
if Lang.First_Source /= No_Source then if Lang.First_Source /= No_Source then
return True; return True;
end if; end if;
Lang := Lang.Next; Lang := Lang.Next;
end loop; end loop;
...@@ -617,6 +619,7 @@ package body Prj is ...@@ -617,6 +619,7 @@ package body Prj is
function Get_From_Tree (P : Project_Id) return Project_Id is function Get_From_Tree (P : Project_Id) return Project_Id is
List : Project_List := Tree.Projects; List : Project_List := Tree.Projects;
begin begin
if not Has_Sources (P) then if not Has_Sources (P) then
while List /= null loop while List /= null loop
...@@ -625,6 +628,7 @@ package body Prj is ...@@ -625,6 +628,7 @@ package body Prj is
then then
return List.Project; return List.Project;
end if; end if;
List := List.Next; List := List.Next;
end loop; end loop;
end if; end if;
...@@ -632,8 +636,12 @@ package body Prj is ...@@ -632,8 +636,12 @@ package body Prj is
return P; return P;
end Get_From_Tree; end Get_From_Tree;
-- Local variables
List : Project_List; List : Project_List;
-- Start of processing for Recursive_Check
begin begin
if not Seen_Name.Contains (Project.Name) then if not Seen_Name.Contains (Project.Name) then
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- S p e c -- -- S p e c --
-- -- -- --
-- Copyright (C) 1992-2011, Free Software Foundation, Inc. -- -- Copyright (C) 1992-2012, Free Software Foundation, Inc. --
-- -- -- --
-- GNAT is free software; you can redistribute it and/or modify it under -- -- 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- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -30,16 +30,17 @@ ...@@ -30,16 +30,17 @@
------------------------------------------------------------------------------ ------------------------------------------------------------------------------
-- This package defines the set of restriction identifiers. It is a generic -- This package defines the set of restriction identifiers. It is a generic
-- package that is instantiated by the compiler/binder in package Rident, and -- package that is instantiated by the binder for output of the restrictions
-- is instantiated in package System.Restrictions for use at run-time. -- structure, and is instantiated in package System.Restrictions for use at
-- run-time.
-- The reason that we make this a generic package is so that in the case of -- The reason that we make this a generic package is so that in the case of
-- the instantiation in Rident for use at compile time and bind time, we can -- the instantiation in the binder, we can generate normal image tables for
-- generate normal image tables for the enumeration types, which are needed -- the enumeration types, which are needed for diagnostic and informational
-- for diagnostic and informational messages. At run-time we really do not -- messages as well as for identification of restrictions. At run-time we
-- want to waste the space for these image tables, and they are not needed, -- really do not want to waste the space for these image tables, and they are
-- so we can do the instantiation under control of Discard_Names to remove -- not needed, so we can do the instantiation under control of Discard_Names
-- the tables. -- to remove the tables.
pragma Compiler_Unit; pragma Compiler_Unit;
......
...@@ -244,6 +244,9 @@ package body Sem_Ch9 is ...@@ -244,6 +244,9 @@ package body Sem_Ch9 is
---------------- ----------------
function Check_Node (N : Node_Id) return Traverse_Result is function Check_Node (N : Node_Id) return Traverse_Result is
-- The following function belongs in sem_eval ???
function Is_Static_Function (Attr : Node_Id) return Boolean; function Is_Static_Function (Attr : Node_Id) return Boolean;
-- Given an attribute reference node Attr, return True if -- Given an attribute reference node Attr, return True if
-- Attr denotes a static function according to the rules in -- Attr denotes a static function according to the rules in
......
...@@ -953,18 +953,24 @@ package Snames is ...@@ -953,18 +953,24 @@ package Snames is
Last_Attribute_Name : constant Name_Id := N + $; Last_Attribute_Name : constant Name_Id := N + $;
-- Names of internal attributes. They are not real attributes but special -- Names of internal attributes. They are not real attributes but special
-- names used internally by GNAT in order to deal with certain delayed -- names used internally by GNAT in order to deal with delayed aspects
-- aspects (Aspect_CPU, Aspect_Dispatching_Domain, -- (Aspect_CPU, Aspect_Dispatching_Domain, Aspect_Interrupt_Priority) that
-- Aspect_Interrupt_Priority) that don't have corresponding pragmas or -- don't have corresponding pragmas or user-referencable attributes.
-- user-referencable attributes. It is convenient to have these internal
-- attributes available in processing the aspects, since the normal -- It is convenient to have these internal attributes available for
-- approach is to convert an aspect into its corresponding pragma or -- processing the aspects, since the normal approach is to convert an
-- attribute specification. -- aspect into its corresponding pragma or attribute specification.
-- These attributes do have Attribute_Id values so that case statements
-- on Attribute_Id include these cases, but they are NOT included in the
-- Attribute_Name subtype defined above, which is typically used in the
-- front end for checking syntax of submitted programs (where the use of
-- internal attributes is not permitted).
First_Internal_Attribute_Name : constant Name_Id := N + $; First_Internal_Attribute_Name : constant Name_Id := N + $;
Name_CPU : constant Name_Id := N + $; -- INT Name_CPU : constant Name_Id := N + $;
Name_Dispatching_Domain : constant Name_Id := N + $; -- INT Name_Dispatching_Domain : constant Name_Id := N + $;
Name_Interrupt_Priority : constant Name_Id := N + $; -- INT Name_Interrupt_Priority : constant Name_Id := N + $;
Last_Internal_Attribute_Name : constant Name_Id := N + $; Last_Internal_Attribute_Name : constant Name_Id := N + $;
-- Names of recognized locking policy identifiers -- Names of recognized locking policy identifiers
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment