]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
ada: Fix code generation when there is no No_Finalization restiction
authorVadim Godunko <godunko@adacore.com>
Sun, 13 Jul 2025 05:41:22 +0000 (09:41 +0400)
committerMarc Poulhiès <dkm@gcc.gnu.org>
Mon, 15 Sep 2025 12:59:26 +0000 (14:59 +0200)
Check whether library is elaborated is not generated when there is not
standard library available on target.

gcc/ada/ChangeLog:

* bindgen.adb (Gen_Adafinal): Don't generate code when
use of standard library suppressed.

gcc/ada/bindgen.adb

index cb39af67f9a5dfdadeb986a5fe8de534e69c06c0..14367ebe97a746e74885676010c6a48e452087c1 100644 (file)
@@ -490,7 +490,9 @@ package body Bindgen is
       WBI ("");
       WBI ("   begin");
 
-      if not CodePeer_Mode then
+      if not CodePeer_Mode
+        and not Suppress_Standard_Library_On_Target
+      then
          WBI ("      if not Is_Elaborated then");
          WBI ("         return;");
          WBI ("      end if;");