From: Vincent Celier Date: Tue, 27 May 2008 10:14:01 +0000 (+0200) Subject: 2008-05-27 Vincent Celier X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=66f3c0b0de7832717ca5ebace7f72a6ffb101569;p=gcc.git 2008-05-27 Vincent Celier * prj-nmsc.adb: (Check_File): Make sure that a unit that replaces the same unit in a project being extended is properly processed. From-SVN: r136000 --- diff --git a/gcc/ada/prj-nmsc.adb b/gcc/ada/prj-nmsc.adb index bbb0ec8f9ff..c69c7b31605 100644 --- a/gcc/ada/prj-nmsc.adb +++ b/gcc/ada/prj-nmsc.adb @@ -8593,13 +8593,21 @@ package body Prj.Nmsc is if Unit /= No_Name and then Src_Data.Unit = Unit - and then Src_Data.Kind /= Kind + and then + ((Src_Data.Kind = Spec and then Kind = Impl) + or else + (Src_Data.Kind = Impl and then Kind = Spec)) then Other_Part := Source; elsif (Unit /= No_Name and then Src_Data.Unit = Unit - and then Src_Data.Kind = Kind) + and then + (Src_Data.Kind = Kind + or else + (Src_Data.Kind = Sep and then Kind = Impl) + or else + (Src_Data.Kind = Impl and then Kind = Sep))) or else (Unit = No_Name and then Src_Data.File = File_Name) then -- Duplication of file/unit in same project is only