prj-proc.adb (Recursive_Process): Make sure that the project display name is never...
authorVincent Celier <celier@adacore.com>
Fri, 31 Oct 2014 11:47:11 +0000 (11:47 +0000)
committerArnaud Charlet <charlet@gcc.gnu.org>
Fri, 31 Oct 2014 11:47:11 +0000 (12:47 +0100)
2014-10-31  Vincent Celier  <celier@adacore.com>

* prj-proc.adb (Recursive_Process): Make sure that the project
display name is never No_Name.

From-SVN: r216970

gcc/ada/ChangeLog
gcc/ada/prj-proc.adb

index 96f94e2f2478ce2fa082f2dbfd5e9f92bd687526..482f230e0d96292f7c1ac6aef128b7e7b2be9e8c 100644 (file)
@@ -1,3 +1,8 @@
+2014-10-31  Vincent Celier  <celier@adacore.com>
+
+       * prj-proc.adb (Recursive_Process): Make sure that the project
+       display name is never No_Name.
+
 2014-10-31  Ed Schonberg  <schonberg@adacore.com>
 
        * sem_attr.adb (Analyze_Access_Attribute): Do not emit error
index 9eb281468e43eae9c19cc7c6b5ea8a53db611c52..7fffc3210f55f4132538a0f1a1c4ea604a300818 100644 (file)
@@ -2994,7 +2994,15 @@ package body Prj.Proc is
             Processed_Projects.Set (Name, Project);
 
             Project.Name := Name;
-            Project.Display_Name := Name_Node.Display_Name;
+
+            --  Make sure that the project display name is never No_Name
+
+            if Name_Node.Display_Name = No_Name then
+               Project.Display_Name := Name;
+            else
+               Project.Display_Name := Name_Node.Display_Name;
+            end if;
+
             Get_Name_String (Name);
 
             --  If name starts with the virtual prefix, flag the project as