* [COMMITTED] ada: Remove dead code for GNATprove inlining
@ 2024-01-09 13:15 Marc Poulhiès
0 siblings, 0 replies; only message in thread
From: Marc Poulhiès @ 2024-01-09 13:15 UTC (permalink / raw)
To: gcc-patches; +Cc: Piotr Trojanek
From: Piotr Trojanek <trojanek@adacore.com>
Removed code was dead because it could only be executed when
Back_End_Inlining is True and that flag is always false in
GNATprove_Mode.
gcc/ada/
* inline.adb (Cannot_Inline): Cleanup use of 'Length; remove
dead code.
Tested on x86_64-pc-linux-gnu, committed on master.
---
gcc/ada/inline.adb | 15 ++-------------
1 file changed, 2 insertions(+), 13 deletions(-)
diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb
index cc2bc3ac18a..f6bed4d26e3 100644
--- a/gcc/ada/inline.adb
+++ b/gcc/ada/inline.adb
@@ -1983,9 +1983,9 @@ package body Inline is
then
declare
Len1 : constant Positive :=
- String (String'("cannot inline"))'Length;
+ String'("cannot inline")'Length;
Len2 : constant Positive :=
- String (String'("info: no contextual analysis of"))'Length;
+ String'("info: no contextual analysis of")'Length;
New_Msg : String (1 .. Msg'Length + Len2 - Len1);
@@ -2044,17 +2044,6 @@ package body Inline is
Error_Msg_NE (Msg (Msg'First .. Msg'Last - 1), N, Subp);
- -- In GNATprove mode, issue an info message when -gnatd_f is set and
- -- Suppress_Info is False, and indicate that the subprogram is not
- -- always inlined by setting flag Is_Inlined_Always to False.
-
- elsif GNATprove_Mode then
- Set_Is_Inlined_Always (Subp, False);
-
- if Debug_Flag_Underscore_F and not Suppress_Info then
- Error_Msg_NE (Msg, N, Subp);
- end if;
-
else
-- Do not emit warning if this is a predefined unit which is not
--
2.43.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-01-09 13:15 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-09 13:15 [COMMITTED] ada: Remove dead code for GNATprove inlining Marc Poulhiès
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).