From b2738a24942ace51f50c6f1257225c9845677906 Mon Sep 17 00:00:00 2001 From: charlet Date: Tue, 28 Jul 2009 08:21:57 +0000 Subject: 2009-07-28 Robert Dewar * prj-nmsc.adb, g-expect.adb, prj.ads: Minor reformatting git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@150148 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ada/ChangeLog | 4 ++++ gcc/ada/g-expect.adb | 3 +++ gcc/ada/prj-nmsc.adb | 3 ++- gcc/ada/prj.ads | 17 ++++++++++++----- 4 files changed, 21 insertions(+), 6 deletions(-) (limited to 'gcc/ada') diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index c916da42339..a8df5432629 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,7 @@ +2009-07-28 Robert Dewar + + * prj-nmsc.adb, g-expect.adb, prj.ads: Minor reformatting + 2009-07-28 Sergey Rybin * gnat_ugn.texi: Add section about gnatcheck rule exemption. diff --git a/gcc/ada/g-expect.adb b/gcc/ada/g-expect.adb index 5f88f63f076..02bc6cf8a79 100644 --- a/gcc/ada/g-expect.adb +++ b/gcc/ada/g-expect.adb @@ -1196,6 +1196,7 @@ package body GNAT.Expect is pragma Warnings (Off, Pipe3); On_Windows : constant Boolean := Directory_Separator = '\'; + -- This is ugly, we need a better way of doing this test ??? Input : File_Descriptor; Output : File_Descriptor; @@ -1203,8 +1204,10 @@ package body GNAT.Expect is begin if On_Windows then + -- Since Windows does not have a separate fork/exec, we need to -- perform the following actions: + -- - save stdin, stdout, stderr -- - replace them by our pipes -- - create the child with process handle inheritance diff --git a/gcc/ada/prj-nmsc.adb b/gcc/ada/prj-nmsc.adb index ee74ad7a3a2..75e4c6ea717 100644 --- a/gcc/ada/prj-nmsc.adb +++ b/gcc/ada/prj-nmsc.adb @@ -730,13 +730,14 @@ package body Prj.Nmsc is Id.File := File_Name; Id.Display_File := Display_File; Id.Dep_Name := Dependency_Name - (File_Name, Lang_Id.Config.Dependency_Kind); + (File_Name, Lang_Id.Config.Dependency_Kind); Id.Naming_Exception := Naming_Exception; -- Add the source id to the Unit_Sources_HT hash table, if the unit name -- is not null. if Unit /= No_Name then + -- Note: we might be creating a dummy unit here, when we in fact have -- a separate. For instance, file file-bar.adb will initially be -- assumed to be the IMPL of unit "file.bar". Only later on (in diff --git a/gcc/ada/prj.ads b/gcc/ada/prj.ads index e2aec8c673a..53229fd89e0 100644 --- a/gcc/ada/prj.ads +++ b/gcc/ada/prj.ads @@ -600,17 +600,24 @@ package Prj is type Source_Kind is (Spec, Impl, Sep); subtype Spec_Or_Body is Source_Kind range Spec .. Impl; + -- The following declarations declare a structure used to store the Name + -- and File and Path names of a unit, with a reference to its GNAT Project + -- File(s). Some units might have neither Spec nor Impl when they were + -- created for a "separate". + type File_Names_Data is array (Spec_Or_Body) of Source_Id; + type Unit_Data is record Name : Name_Id := No_Name; File_Names : File_Names_Data; end record; + type Unit_Index is access all Unit_Data; + No_Unit_Index : constant Unit_Index := null; - -- Name and File and Path names of a unit, with a reference to its - -- GNAT Project File(s). - -- Some units might have neither Spec nor Impl when they were created for - -- a "separate". + -- Used to indicate a null entry for no unit + + -- Structure to define source data type Source_Data is record Project : Project_Id := No_Project; @@ -627,7 +634,7 @@ package Prj is Declared_In_Interfaces : Boolean := False; -- True when source is declared in attribute Interfaces - Alternate_Languages : Language_List; + Alternate_Languages : Language_List := null; -- List of languages a header file may also be, in addition of language -- Language_Name. -- cgit v1.2.1