-- --
-- B o d y --
-- --
--- Copyright (C) 1998-2006, Free Software Foundation, Inc. --
+-- Copyright (C) 1998-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- --
--- ware Foundation; either version 2, or (at your option) any later ver- --
+-- ware Foundation; either version 3, or (at your option) any later ver- --
-- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
-- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License --
-- for more details. You should have received a copy of the GNU General --
--- Public License distributed with GNAT; see file COPYING. If not, write --
--- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
--- Boston, MA 02110-1301, USA. --
+-- Public License distributed with GNAT; see file COPYING3. If not, go to --
+-- http://www.gnu.org/licenses for a complete copy of the license. --
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
-- Extensive contributions were provided by Ada Core Technologies Inc. --
function Get_Key (E : File_Reference) return Cst_String_Access;
function Hash (F : Cst_String_Access) return HTable_Headers;
function Equal (F1, F2 : Cst_String_Access) return Boolean;
- -- The five subprograms above are used to instanciate the static
+ -- The five subprograms above are used to instantiate the static
-- htable to store the files that should be processed.
package File_HTable is new GNAT.HTable.Static_HTable
function Next (E : Declaration_Reference) return Declaration_Reference;
procedure Set_Next (E, Next : Declaration_Reference);
function Get_Key (E : Declaration_Reference) return Cst_String_Access;
- -- The subprograms above are used to instanciate the static
+ -- The subprograms above are used to instantiate the static
-- htable to store the entities that have been found in the application
package Entities_HTable is new GNAT.HTable.Static_HTable
begin
case Ref_Type is
- when 'b' | 'c' | 'm' | 'r' | 'i' | ' ' | 'x' =>
+ when 'b' | 'c' | 'm' | 'r' | 'R' | 'i' | ' ' | 'x' =>
null;
when 'l' | 'w' =>
New_Ref.Next := Declaration.Body_Ref;
Declaration.Body_Ref := New_Ref;
- when 'r' | 'i' | 'l' | ' ' | 'x' | 'w' =>
+ when 'r' | 'R' | 'i' | 'l' | ' ' | 'x' | 'w' =>
New_Ref.Next := Declaration.Ref_Ref;
Declaration.Ref_Ref := New_Ref;
begin
if Index /= 0 then
- return Ada_File_Name (Ada_File_Name'First .. Index) & "ali";
+ return Ada_File_Name (Ada_File_Name'First .. Index)
+ & Osint.ALI_Suffix.all;
else
- return Ada_File_Name & ".ali";
+ return Ada_File_Name & "." & Osint.ALI_Suffix.all;
end if;
end ALI_File_Name;
end if;
if File.Dir = null then
- if Ada.Strings.Fixed.Tail (File.File.all, 3) = "ali" then
+ if Ada.Strings.Fixed.Tail (File.File.all, 3) =
+ Osint.ALI_Suffix.all
+ then
Tmp := Locate_Regular_File
- (Internal_Strip (File.File.all), Directories.Obj_Dir);
+ (Internal_Strip (File.File.all), Directories.Obj_Dir);
else
Tmp := Locate_Regular_File
- (File.File.all, Directories.Src_Dir);
+ (File.File.all, Directories.Src_Dir);
end if;
if Tmp = null then
File_Ref.Visited := False;
-- ??? Do not add a source file to the list. This is true at
- -- least for gnatxref, and probably for gnatfind as wel
+ -- least for gnatxref, and probably for gnatfind as well
if F'Length > 4
- and then F (F'Last - 3 .. F'Last) = ".ali"
+ and then F (F'Last - 3 .. F'Last) = "." & Osint.ALI_Suffix.all
then
Unvisited_Files := new Unvisited_Files_Record'
(File => File_Ref,