aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/errutil.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2016-04-27 15:09:13 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2016-04-27 15:09:13 +0200
commit6d0d18dcb1b2e39d7aaaa7ac2c6a19dd77d8a53d (patch)
treeb5206ef9946339c8dbec6c8e9e033f1bbd9cabe6 /gcc/ada/errutil.adb
parent680d5f6190bf5c90e600f47ee8c9e604d80b2f7b (diff)
downloadgcc-6d0d18dcb1b2e39d7aaaa7ac2c6a19dd77d8a53d.zip
gcc-6d0d18dcb1b2e39d7aaaa7ac2c6a19dd77d8a53d.tar.gz
gcc-6d0d18dcb1b2e39d7aaaa7ac2c6a19dd77d8a53d.tar.bz2
[multiple changes]
2016-04-27 Bob Duff <duff@adacore.com> * a-chtgop.adb (Adjust): Zero the tampering counts on assignment, as is done for the other containers. 2016-04-27 Hristian Kirtchev <kirtchev@adacore.com> * ghost.adb (In_Subprogram_Body_Profile): New routine. (Is_OK_Declaration): Treat an unanalyzed expression function as an OK context. Treat a reference to a Ghost entity as OK when it appears within the profile of a subprogram body. 2016-04-27 Bob Duff <duff@adacore.com> * errout.ads: Document the fact that informational messages don't have to be warnings. * errout.adb (Error_Msg_Internal): In statistics counts, deal correctly with informational messages that are not warnings. (Error_Msg_NEL): Remove useless 'if' aroung Set_Posted, because Set_Posted already checks for errors and ignores others. * erroutc.adb (Prescan_Message): Set Is_Serious_Error to False if Is_Info_Msg; the previous code was assuming that Is_Info_Msg implies Is_Warning_Msg. * errutil.adb (Error_Msg): In statistics counts, deal correctly with informational messages that are not warnings. From-SVN: r235500
Diffstat (limited to 'gcc/ada/errutil.adb')
-rw-r--r--gcc/ada/errutil.adb19
1 files changed, 12 insertions, 7 deletions
diff --git a/gcc/ada/errutil.adb b/gcc/ada/errutil.adb
index 9fd67e1..d4e9510 100644
--- a/gcc/ada/errutil.adb
+++ b/gcc/ada/errutil.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 1991-2014, Free Software Foundation, Inc. --
+-- Copyright (C) 1991-2016, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
@@ -302,18 +302,23 @@ package body Errutil is
Errors.Table (Cur_Msg).Next := Next_Msg;
- -- Bump appropriate statistics count
+ -- Bump appropriate statistics counts
- if Errors.Table (Cur_Msg).Warn
+ if Errors.Table (Cur_Msg).Info then
+ Info_Messages := Info_Messages + 1;
+
+ -- Could be (usually is) both "info" and "warning"
+
+ if Errors.Table (Cur_Msg).Warn then
+ Warnings_Detected := Warnings_Detected + 1;
+ end if;
+
+ elsif Errors.Table (Cur_Msg).Warn
or else
Errors.Table (Cur_Msg).Style
then
Warnings_Detected := Warnings_Detected + 1;
- if Errors.Table (Cur_Msg).Info then
- Info_Messages := Info_Messages + 1;
- end if;
-
elsif Errors.Table (Cur_Msg).Check then
Check_Messages := Check_Messages + 1;