From 7f4db7c80779ecbc57d1146654daf0acfe18de66 Mon Sep 17 00:00:00 2001 From: rus Date: Mon, 9 Nov 2009 20:58:24 +0000 Subject: merge from trunk git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/profile-stdlib@154052 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ada/gnatbind.adb | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'gcc/ada/gnatbind.adb') diff --git a/gcc/ada/gnatbind.adb b/gcc/ada/gnatbind.adb index 48eceb0ff77..fb3dc3d74ba 100644 --- a/gcc/ada/gnatbind.adb +++ b/gcc/ada/gnatbind.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2008, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2009, 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- -- @@ -838,6 +838,28 @@ begin end if; end loop; + -- Subunits do not appear in the elaboration table because they + -- are subsumed by their parent units, but we need to list them + -- for other tools. For now they are listed after other files, + -- rather than right after their parent, since there is no easy + -- link between the elaboration table and the ALIs table ??? + -- Note also that subunits may appear repeatedly in the list, + -- if the parent unit appears in the context of several units + -- in the closure. + + for J in Sdep.First .. Sdep.Last loop + if Sdep.Table (J).Subunit_Name /= No_Name + and then not Is_Internal_File_Name (Sdep.Table (J).Sfile) + then + if not Zero_Formatting then + Write_Str (" "); + end if; + + Write_Str (Get_Name_String (Sdep.Table (J).Sfile)); + Write_Eol; + end if; + end loop; + if not Zero_Formatting then Write_Eol; end if; -- cgit v1.2.1