diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-08-29 13:01:34 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-08-29 13:01:34 +0000 |
commit | 962f9261e0cab281bcdaaa9974a2ea33d1cb39eb (patch) | |
tree | 7412f8c28844cfbce864ebf8faec6233f94235e8 /gcc/ada/prj-conf.adb | |
parent | f06ecec3d0e90c93a30136495994a25ba387cd07 (diff) | |
download | gcc-962f9261e0cab281bcdaaa9974a2ea33d1cb39eb.tar.gz |
2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
* s-finmas.adb (Finalize): Check Finalize_Address of the master rather
than the current node.
* s-finmas.ads: Move field Finalize_Address from type FM_Node to
Finalization_Master. The list headers have two fields instead of three.
This should fix alignment issue but subpool allocations are now
unusable. Alphabetize subprograms.
* s-stposu.adb (Allocate_Any_Controlled): Use the offset rather than
the size of the header when converting the beginning of the object to
a FM_Node. Set the master's Finalize_Address attribute if not already
set.
(Deallocate_Any_Controlled): Use the offset rather than the size of the
header when converting the beginning of the object to a FM_Node.
2011-08-29 Gary Dismukes <dismukes@adacore.com>
* exp_ch11.adb (Expand_N_Raise_Statement): Don't suppress expansion of
reraise when compiling for CodePeer.
2011-08-29 Arnaud Charlet <charlet@adacore.com>
* a-iteint.ads, Makefile.rtl: Add missing compilation of a-iteint.ads,
now needed by a-convec.adb. Fix warning.
2011-08-29 Hristian Kirtchev <kirtchev@adacore.com>
* exp_util.adb (Build_Allocate_Deallocate_Proc): Add a guard for the
processing of TSS routine Finalize_Address when compiling in
CodePeer_Mode.
2011-08-29 Thomas Quinot <quinot@adacore.com>
* a-strunb.ads, einfo.ads, g-comlin.ads, sem_ch6.adb,
sem_warn.adb: Minor reformatting.
2011-08-29 Emmanuel Briot <briot@adacore.com>
* prj-conf.adb (Get_Config_Switches): Also collect the list of
languages from aggregated projects.
2011-08-29 Yannick Moy <moy@adacore.com>
* lib-xref-alfa.adb, lib-xref.ads (Traverse_Declarations_Or_Statements,
Traverse_Handled_Statement_Sequence, Traverse_Package_Body,
Traverse_Package_Declaration, Traverse_Subprogram_Body,
Traverse_Compilation_Unit): Add a parameter Inside_Stubs so that bodies
for stubs are traversed too when parameter is set
(Traverse_All_Compilation_Units): Traverse without going inside stubs
(Traverse_Declarations_Or_Statements): Do the special traversing for
stubs when required.
* sem_util.adb, sem_util.ads (Get_Body_From_Stub): New function to
return subprogram or package body from stub.
(Is_Subprogram_Stub_Without_Prior_Declaration): New function to detect
stubs without prior subprogram decl.
2011-08-29 Vasiliy Fofanov <fofanov@adacore.com>
* gnat_ugn.texi: Fix typo.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@178219 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/prj-conf.adb')
-rw-r--r-- | gcc/ada/prj-conf.adb | 70 |
1 files changed, 44 insertions, 26 deletions
diff --git a/gcc/ada/prj-conf.adb b/gcc/ada/prj-conf.adb index a1d9fe96b05..c6e37ee3da9 100644 --- a/gcc/ada/prj-conf.adb +++ b/gcc/ada/prj-conf.adb @@ -722,28 +722,32 @@ package body Prj.Conf is -- Hash table to keep the languages used in the project tree IDE : constant Package_Id := - Value_Of (Name_Ide, Project.Decl.Packages, Shared); - - Prj_Iter : Project_List; - List : String_List_Id; - Elem : String_Element; - Lang : Name_Id; - Variable : Variable_Value; - Name : Name_Id; - Count : Natural; - Result : Argument_List_Access; - - Check_Default : Boolean; - - begin - Prj_Iter := Project_Tree.Projects; - while Prj_Iter /= null loop - if Might_Have_Sources (Prj_Iter.Project) then + Value_Of (Name_Ide, Project.Decl.Packages, Shared); + + procedure Add_Config_Switches_For_Project + (Project : Project_Id; + Tree : Project_Tree_Ref; + With_State : in out Integer); + -- Add all --config switches for this project. This is also called + -- for aggregate projects. + + procedure Add_Config_Switches_For_Project + (Project : Project_Id; + Tree : Project_Tree_Ref; + With_State : in out Integer) + is + pragma Unreferenced (With_State); + Shared : constant Shared_Project_Tree_Data_Access := Tree.Shared; + + Variable : Variable_Value; + Check_Default : Boolean; + Lang : Name_Id; + List : String_List_Id; + Elem : String_Element; + begin + if Might_Have_Sources (Project) then Variable := - Value_Of - (Name_Languages, - Prj_Iter.Project.Decl.Attributes, - Shared); + Value_Of (Name_Languages, Project.Decl.Attributes, Shared); if Variable = Nil_Variable_Value or else Variable.Default @@ -752,13 +756,13 @@ package body Prj.Conf is -- project, or if it extends a project with no Languages, -- check for Default_Language. - Check_Default := Prj_Iter.Project.Extends = No_Project; + Check_Default := Project.Extends = No_Project; if not Check_Default then Variable := Value_Of (Name_Languages, - Prj_Iter.Project.Extends.Decl.Attributes, + Project.Extends.Decl.Attributes, Shared); Check_Default := Variable /= Nil_Variable_Value @@ -769,7 +773,7 @@ package body Prj.Conf is Variable := Value_Of (Name_Default_Language, - Prj_Iter.Project.Decl.Attributes, + Project.Decl.Attributes, Shared); if Variable /= Nil_Variable_Value @@ -805,9 +809,23 @@ package body Prj.Conf is end loop; end if; end if; + end Add_Config_Switches_For_Project; - Prj_Iter := Prj_Iter.Next; - end loop; + procedure For_Every_Imported_Project is new For_Every_Project_Imported + (State => Integer, Action => Add_Config_Switches_For_Project); + + Name : Name_Id; + Count : Natural; + Result : Argument_List_Access; + Variable : Variable_Value; + Dummy : Integer := 0; + + begin + For_Every_Imported_Project + (By => Project, + Tree => Project_Tree, + With_State => Dummy, + Include_Aggregated => True); Name := Language_Htable.Get_First; Count := 0; |