aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/inline.adb
diff options
context:
space:
mode:
authorYannick Moy <moy@adacore.com>2018-09-26 09:19:12 +0000
committerPierre-Marie de Rodat <pmderodat@gcc.gnu.org>2018-09-26 09:19:12 +0000
commita30a69c1229cbf5270d2048299da5b9ae171e226 (patch)
tree07304bcaecb98507dd548408fb8789a6426b2d0f /gcc/ada/inline.adb
parent2d9c4206c9d18b39f4d1c87ddbbda75238b7bf19 (diff)
downloadgcc-a30a69c1229cbf5270d2048299da5b9ae171e226.zip
gcc-a30a69c1229cbf5270d2048299da5b9ae171e226.tar.gz
gcc-a30a69c1229cbf5270d2048299da5b9ae171e226.tar.bz2
[Ada] Do not issue by default info messages for inlining in GNATprove
Info messages about lack of inlining for analysis in GNATprove may be confusing to users. They are now only issued when GNATprove is called with switch --info, which it passes on to gnat2why with switch -gnatd_f. There is no effect on compilation. 2018-09-26 Yannick Moy <moy@adacore.com> gcc/ada/ * debug.adb: Add use for -gnatd_f switch. * inline.adb (Cannot_Inline): Only issue info message for failure to inline in GNATprove mode when switch -gnatd_f is used. From-SVN: r264629
Diffstat (limited to 'gcc/ada/inline.adb')
-rw-r--r--gcc/ada/inline.adb21
1 files changed, 14 insertions, 7 deletions
diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb
index 8f0b75d..72991fa 100644
--- a/gcc/ada/inline.adb
+++ b/gcc/ada/inline.adb
@@ -1607,13 +1607,16 @@ package body Inline is
then
null;
- -- In GNATprove mode, issue a warning, and indicate that the
- -- subprogram is not always inlined by setting flag Is_Inlined_Always
- -- to False.
+ -- In GNATprove mode, issue a warning when -gnatd_f is set, 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);
- Error_Msg_NE (Msg & "p?", N, Subp);
+
+ if Debug_Flag_Underscore_F then
+ Error_Msg_NE (Msg & "p?", N, Subp);
+ end if;
elsif Has_Pragma_Inline_Always (Subp) then
@@ -1634,12 +1637,16 @@ package body Inline is
Error_Msg_NE (Msg (Msg'First .. Msg'Last - 1), N, Subp);
- -- In GNATprove mode, issue a warning, and indicate that the subprogram
- -- is not always inlined by setting flag Is_Inlined_Always to False.
+ -- In GNATprove mode, issue a warning when -gnatd_f is set, 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);
- Error_Msg_NE (Msg & "p?", N, Subp);
+
+ if Debug_Flag_Underscore_F then
+ Error_Msg_NE (Msg & "p?", N, Subp);
+ end if;
else