diff mbox series

[Ada] Plug minor loophole for integer named number

Message ID 20191010152947.GA87574@adacore.com
State New
Headers show
Series [Ada] Plug minor loophole for integer named number | expand

Commit Message

Pierre-Marie de Rodat Oct. 10, 2019, 3:29 p.m. UTC
Analyze_Number_Declaration contains a fast track for the case where the
expression of an integer named number is a literal, but it fails to set
the Debug_Info_Needed flag on the named number.

No functional changes.

Tested on x86_64-pc-linux-gnu, committed on trunk

2019-10-10  Eric Botcazou  <ebotcazou@adacore.com>

gcc/ada/

	* sem_ch3.adb (Analyze_Number_Declaration): Set
	Debug_Info_Needed in the case where the expression is an integer
	literal.
diff mbox series

Patch

--- gcc/ada/sem_ch3.adb
+++ gcc/ada/sem_ch3.adb
@@ -3522,6 +3522,8 @@  package body Sem_Ch3 is
          Set_Etype     (Id, Universal_Integer);
          Set_Ekind     (Id, E_Named_Integer);
          Set_Is_Frozen (Id, True);
+
+         Set_Debug_Info_Needed (Id);
          return;
       end if;