From 25e6c4403919c5e6f4f6c306faf380c619b9c84f Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Sat, 17 May 2025 01:20:19 +0200 Subject: [PATCH] ada: Small tweak to latest change Unlike RTE, RTU_Entity alone does not cause the unit to be loaded. gcc/ada/ChangeLog: * exp_ch7.adb (Shift_Address_For_Descriptor): Add dummy variable to make sure that System_Storage_Elements is loaded. --- gcc/ada/exp_ch7.adb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gcc/ada/exp_ch7.adb b/gcc/ada/exp_ch7.adb index 9abdcc18a57..4d2b8348048 100644 --- a/gcc/ada/exp_ch7.adb +++ b/gcc/ada/exp_ch7.adb @@ -8868,7 +8868,9 @@ package body Exp_Ch7 is Typ : Entity_Id; Op_Nam : Name_Id) return Node_Id is - Loc : constant Source_Ptr := Sloc (Addr); + Loc : constant Source_Ptr := Sloc (Addr); + Dummy : constant Entity_Id := RTE (RE_Storage_Offset); + -- Make sure System_Storage_Elements is loaded for RTU_Entity begin -- Generate: -- 2.47.2