summaryrefslogtreecommitdiff
path: root/gcc/ada
diff options
context:
space:
mode:
authorRobert Dewar <dewar@gnat.com>2001-12-05 01:10:00 +0000
committerGeert Bosch <bosch@gcc.gnu.org>2001-12-05 02:10:00 +0100
commit0ae8475357b8d605200056d51e0946d40ff57e39 (patch)
tree1c98805e312d3462956578c47e990b6fecfa423b /gcc/ada
parent63db260effc0ce9622afe7c43fb8b4eabd5ad3f9 (diff)
downloadgcc-0ae8475357b8d605200056d51e0946d40ff57e39.tar.gz
* errout.adb: Minor reformatting
From-SVN: r47640
Diffstat (limited to 'gcc/ada')
-rw-r--r--gcc/ada/ChangeLog4
-rw-r--r--gcc/ada/errout.adb15
2 files changed, 14 insertions, 5 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index 02bc72d4575..5d762463889 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,5 +1,9 @@
2001-12-04 Robert Dewar <dewar@gnat.com>
+ * errout.adb: Minor reformatting
+
+2001-12-04 Robert Dewar <dewar@gnat.com>
+
* exp_util.adb: Minor reformatting from last change
* errout.adb (Check_For_Warning): For a Raised_Constraint_Error node
diff --git a/gcc/ada/errout.adb b/gcc/ada/errout.adb
index 28b0c4c212a..74fc82124c7 100644
--- a/gcc/ada/errout.adb
+++ b/gcc/ada/errout.adb
@@ -1937,8 +1937,6 @@ package body Errout is
Traverse_Func (Check_For_Warning);
-- This defines the traversal operation
- Discard : Traverse_Result;
-
-----------------------
-- Check_For_Warning --
-----------------------
@@ -1951,6 +1949,10 @@ package body Errout is
-- Returns True for a message that is to be removed. Also adjusts
-- warning count appropriately.
+ -------------------
+ -- To_Be_Removed --
+ -------------------
+
function To_Be_Removed (E : Error_Msg_Id) return Boolean is
begin
if E /= No_Error_Msg
@@ -1984,7 +1986,6 @@ package body Errout is
if Nkind (N) = N_Raise_Constraint_Error
and then Original_Node (N) /= N
then
-
-- Warnings may have been posted on subexpressions of
-- the original tree. We temporarily replace the raise
-- statement with the original expression to remove
@@ -1992,7 +1993,7 @@ package body Errout is
-- any node in the current tree.
declare
- Old : Node_Id := N;
+ Old : Node_Id := N;
Status : Traverse_Result;
begin
@@ -2011,7 +2012,11 @@ package body Errout is
begin
if Warnings_Detected /= 0 then
- Discard := Check_All_Warnings (N);
+ declare
+ Discard : Traverse_Result;
+ begin
+ Discard := Check_All_Warnings (N);
+ end;
end if;
end Remove_Warning_Messages;