diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2009-09-16 14:30:39 +0200 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2009-09-16 14:30:39 +0200 |
commit | 75a648339844b6eeaef9553841766448e43b63fd (patch) | |
tree | 3b8e0a0e73a769e176fefad050be04b6ff2e0cd8 /gcc/ada/prj.ads | |
parent | bac7206de028db55def3c7ec5c9b21169bb2fc20 (diff) | |
download | gcc-75a648339844b6eeaef9553841766448e43b63fd.zip gcc-75a648339844b6eeaef9553841766448e43b63fd.tar.gz gcc-75a648339844b6eeaef9553841766448e43b63fd.tar.bz2 |
[multiple changes]
2009-09-16 Thomas Quinot <quinot@adacore.com>
* freeze.adb, exp_intr.adb (Expand_Intrinsic_Call): Leave calls to
intrinsics untouched (to be expanded later on by gigi) if an external
name has been specified.
(Freeze_Entity): Do not generate a default external name for
imported subprograms with convention Intrinsic (so that the above code
can identify the case where an external name has been explicitly
provided).
* s-oscons-tmplt.c: Quote TARGET_OS early so that it is not erroneously
replaced by something else due to an existing #define clause.
2009-09-16 Ed Schonberg <schonberg@adacore.com>
* sinfo.ads, sinfo.adb (Is_Accessibility_Actual): New flag on
Parameter_Association node, created for the extra actual generated for
an access parameter of a function that dispatches on result, to prevent
double generation of such actuals when the call is rewritten is a
dispatching call.
* exp_ch6.adb (Expand_Call): Set Is_Accessibility_Actual when needed.
* exp_disp.adb (Expand_Dispatching_Call): Do not transfer extra actuals
that carry this flag when rewriting the original call as a dispatching
call, after propagating the controlling tag.
2009-09-16 Vincent Celier <celier@adacore.com>
* prj-nmsc.adb (Add_Source): New parameter Source_Dir_Rank to be put
in the source data.
(Check_File): New parameter Source_Dir_Rank, to check if a duplicate
source is allowed.
(Find_Source_Dirs): New parameter Rank to be recorded with the source
directories.
(Search_Directories): Call Check_File with the rank of the directory
* prj.adb (Project_Empty): Add new component Source_Dir_Ranks
(Free): Free also Number_Lists
(Reset): Init also Number_Lists
* prj.ads (Number_List_Table): New dynamic table for lists of numbers
(Source_Data): New component Source_Dir_Rank. Remove component
Known_Order_Of_Source_Dirs, no longer needed.
(Project_Data): New component Source_Dir_Ranks
(Project_Tree_Data): New components Number_Lists
From-SVN: r151749
Diffstat (limited to 'gcc/ada/prj.ads')
-rw-r--r-- | gcc/ada/prj.ads | 31 |
1 files changed, 26 insertions, 5 deletions
diff --git a/gcc/ada/prj.ads b/gcc/ada/prj.ads index 76eb59a..502ace9 100644 --- a/gcc/ada/prj.ads +++ b/gcc/ada/prj.ads @@ -314,7 +314,23 @@ package Prj is Table_Low_Bound => 1, Table_Initial => 10, Table_Increment => 100); - -- The table for lists of names used in package Language_Processing + -- The table for lists of names + + type Number_List_Index is new Nat; + No_Number_List : constant Number_List_Index := 0; + + type Number_Node is record + Number : Natural := 0; + Next : Number_List_Index := No_Number_List; + end record; + + package Number_List_Table is new GNAT.Dynamic_Tables + (Table_Component_Type => Number_Node, + Table_Index_Type => Number_List_Index, + Table_Low_Bound => 1, + Table_Initial => 10, + Table_Increment => 100); + -- The table for lists of numbers package Mapping_Files_Htable is new Simple_HTable (Header_Num => Header_Num, @@ -623,6 +639,12 @@ package Prj is Project : Project_Id := No_Project; -- Project of the source + Source_Dir_Rank : Natural := 0; + -- The rank of the source directory in list declared with attribute + -- Source_Dirs. Two source files with the same name cannot appears in + -- different directory with the same rank. That can happen when the + -- recursive notation <dir>/** is used in attribute Source_Dirs. + Language : Language_Ptr := No_Language_Index; -- Index of the language. This is an index into -- Project_Tree.Languages_Data. @@ -717,6 +739,7 @@ package Prj is No_Source_Data : constant Source_Data := (Project => No_Project, + Source_Dir_Rank => 0, Language => No_Language_Index, In_Interfaces => True, Declared_In_Interfaces => False, @@ -1155,10 +1178,7 @@ package Prj is Source_Dirs : String_List_Id := Nil_String; -- The list of all the source directories - Known_Order_Of_Source_Dirs : Boolean := True; - -- False, if there is any /** in the Source_Dirs, because in this case - -- the ordering of the source subdirs depend on the OS. If True, - -- duplicate file names in the same project file are allowed. + Source_Dir_Ranks : Number_List_Index := No_Number_List; Ada_Include_Path : String_Access := null; -- The cached value of source search path for this project file. Set by @@ -1273,6 +1293,7 @@ package Prj is type Project_Tree_Data is record Name_Lists : Name_List_Table.Instance; + Number_Lists : Number_List_Table.Instance; String_Elements : String_Element_Table.Instance; Variable_Elements : Variable_Element_Table.Instance; Array_Elements : Array_Element_Table.Instance; |