From: Ronan Desplanques <[email protected]>

This fixes the criterion that determines whether to add finalization
collection extra formals to BIP functions.

gcc/ada/ChangeLog:

        * exp_ch6.adb (Needs_BIP_Collection): Fix condition.

Tested on x86_64-pc-linux-gnu, committed on master.

---
 gcc/ada/exp_ch6.adb | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/gcc/ada/exp_ch6.adb b/gcc/ada/exp_ch6.adb
index 09156d98702..6a322be004f 100644
--- a/gcc/ada/exp_ch6.adb
+++ b/gcc/ada/exp_ch6.adb
@@ -9932,8 +9932,7 @@ package body Exp_Ch6 is
 
       return not Restriction_Active (No_Finalization)
         and then (Needs_Finalization (Typ) or else Is_Tagged_Type (Typ))
-        and then not Has_Relaxed_Finalization (Typ)
-        and then not Has_Foreign_Convention (Typ);
+        and then not Has_Relaxed_Finalization (Typ);
    end Needs_BIP_Collection;
 
    --------------------------
-- 
2.53.0

Reply via email to