gprep.adb (Process_Files.Process_One_File): Use full file name when issuing pragma...
authorVincent Celier <celier@adacore.com>
Fri, 6 Apr 2007 09:22:50 +0000 (11:22 +0200)
committerArnaud Charlet <charlet@gcc.gnu.org>
Fri, 6 Apr 2007 09:22:50 +0000 (11:22 +0200)
2007-04-06  Vincent Celier  <celier@adacore.com>

* gprep.adb (Process_Files.Process_One_File): Use full file name when
issuing pragma Source_Reference.

From-SVN: r123576

gcc/ada/gprep.adb

index 3a3e2825962c413dd95cfddae8363535ba4e6ed8..e9c37635442f0900cc04ae3f4dc8609e4ffaf11e 100644 (file)
@@ -506,12 +506,13 @@ package body GPrep is
 
          Scanner.Initialize_Scanner (Infile);
 
-         --  Output the SFN pragma if asked to
+         --  Output the pragma Source_Reference if asked to
 
          if Source_Ref_Pragma then
-            Put_Line (Outfile.all, "pragma Source_Reference (1, """ &
-                      Get_Name_String (Sinput.File_Name (Infile)) &
-                      """);");
+            Put_Line
+              (Outfile.all,
+               "pragma Source_Reference (1, """ &
+                 Get_Name_String (Sinput.Full_File_Name (Infile)) & """);");
          end if;
 
          --  Preprocess the input file