summaryrefslogtreecommitdiff
path: root/gcc/ada/make.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-22 14:03:25 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-22 14:03:25 +0000
commit110e0530e94898ff20cc55d37fe7239196282d08 (patch)
treec8905d30c97db074d7cae0cf3f9eaea256f13094 /gcc/ada/make.adb
parentc529cd37e10def62250d824f20f7e9c0c3c14b86 (diff)
downloadgcc-110e0530e94898ff20cc55d37fe7239196282d08.tar.gz
2012-02-22 Pascal Obry <obry@adacore.com>
* s-taprop-mingw.adb (Finalize_TCB): Do not wait on thread handle as this is our own thread. 2012-02-22 Sergey Rybin <rybin@adacore.com frybin> * tree_io.ads: Update ASIS_Version_Number because of the changes in Snames. 2012-02-22 Hristian Kirtchev <kirtchev@adacore.com> * exp_ch7.adb (Create_Finalizer): Suppress elaboration checks on stack-related finalizers. 2012-02-22 Ed Schonberg <schonberg@adacore.com> * sem_ch6.adb (Analyze_Expression_Function): If the construct is a completion, indicate that its formals are the formals of a completion, and as such do not get a cross- reference entry. (Analyze_Subprogram_Specification): Do not generate a definition for the entity of an expression function, because it may be a completion. Definition will be generated if needed when analyzing the generated subprogram declaration. 2012-02-22 Vincent Celier <celier@adacore.com> * make.adb (Check): When checking if an object file is in the correct object directory, get the unit name from a previous call to Check_Source_Info_In_ALI. * makeutl.adb (Check_Source_Info_In_ALI): Return the name of the unit when everything is OK, otherwise return No_Name. * makeutl.ads (Check_Source_Info_In_ALI): Return Name_Id instead of Boolean 2012-02-22 Ed Schonberg <schonberg@adacore.com> * sem_ch4.adb (Find_Equality_Types, Try_One_Interp): In an instance, the operator is visible if an operand is of some numeric type which is not in use or directly visible, and the other operand is a numeric literal. 2012-02-22 Tristan Gingold <gingold@adacore.com> * init.c: Minor code clean up. * gcc-interface/Make-lang.in: Update dependencies. 2012-02-22 Arnaud Charlet <charlet@adacore.com> * gnatlink.adb (Gnatlink): Use -gnatcC in CodePeer_Node, otherwise GCC will generate an object file. 2012-02-22 Vincent Celier <celier@adacore.com> * projects.texi: Correct typo related to "**" in Source_Dirs. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184477 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/make.adb')
-rw-r--r--gcc/ada/make.adb48
1 files changed, 24 insertions, 24 deletions
diff --git a/gcc/ada/make.adb b/gcc/ada/make.adb
index dd211cb4857..0b1cd09b44c 100644
--- a/gcc/ada/make.adb
+++ b/gcc/ada/make.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- 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 --
-- terms of the GNU General Public License as published by the Free Soft- --
@@ -1863,44 +1863,44 @@ package body Make is
end if;
elsif not Read_Only and then Main_Project /= No_Project then
- if not Check_Source_Info_In_ALI (ALI, Project_Tree) then
- ALI := No_ALI_Id;
- return;
- end if;
+ declare
+ Uname : constant Name_Id :=
+ Check_Source_Info_In_ALI (ALI, Project_Tree);
- -- Check that the ALI file is in the correct object directory.
- -- If it is in the object directory of a project that is
- -- extended and it depends on a source that is in one of its
- -- extending projects, then the ALI file is not in the correct
- -- object directory.
+ Udata : Prj.Unit_Index;
- -- First, find the project of this ALI file. As there may be
- -- several projects with the same object directory, we first
- -- need to find the project of the source.
+ begin
+ if Uname = No_Name then
+ ALI := No_ALI_Id;
+ return;
+ end if;
- ALI_Project := No_Project;
+ -- Check that the ALI file is in the correct object
+ -- directory. If it is in the object directory of a project
+ -- that is extended and it depends on a source that is in
+ -- one of its extending projects, then the ALI file is not
+ -- in the correct object directory.
- declare
- Udata : Prj.Unit_Index;
+ -- First, find the project of this ALI file. As there may be
+ -- several projects with the same object directory, we first
+ -- need to find the project of the source.
- begin
- Udata := Units_Htable.Get_First (Project_Tree.Units_HT);
- while Udata /= No_Unit_Index loop
+ ALI_Project := No_Project;
+
+ Udata := Units_Htable.Get (Project_Tree.Units_HT, Uname);
+
+ if Udata /= No_Unit_Index then
if Udata.File_Names (Impl) /= null
and then Udata.File_Names (Impl).File = Source_File
then
ALI_Project := Udata.File_Names (Impl).Project;
- exit;
elsif Udata.File_Names (Spec) /= null
and then Udata.File_Names (Spec).File = Source_File
then
ALI_Project := Udata.File_Names (Spec).Project;
- exit;
end if;
-
- Udata := Units_Htable.Get_Next (Project_Tree.Units_HT);
- end loop;
+ end if;
end;
if ALI_Project = No_Project then