diff options
author | Jakub Jelinek <jakub@redhat.com> | 2008-06-03 11:31:30 +0000 |
---|---|---|
committer | Jakub Jelinek <jakub@redhat.com> | 2008-06-03 11:31:30 +0000 |
commit | 773a92d2ea39e3331e42242d250f8546bdd447c4 (patch) | |
tree | b4122aaed2225e893c275b3dd1a1b1508f5b87b9 /gcc/ada/restrict.adb | |
parent | b525904898beb1c54f70cb512711513be2f53a92 (diff) |
svn merge -r136014:136314 svn+ssh://gcc.gnu.org/svn/gcc/trunk/
git-svn-id: https://gcc.gnu.org/svn/gcc/branches/gomp-3_0-branch@136316 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/restrict.adb')
-rw-r--r-- | gcc/ada/restrict.adb | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/gcc/ada/restrict.adb b/gcc/ada/restrict.adb index 5049c5b1be4..2f1bd5dec3d 100644 --- a/gcc/ada/restrict.adb +++ b/gcc/ada/restrict.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2007, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2008, 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- -- @@ -321,7 +321,16 @@ package body Restrict is if Restriction_Warnings (R) then Restriction_Msg ("|violation of restriction %#?", Rimage, N); else - Restriction_Msg ("|violation of restriction %#", Rimage, N); + -- Normally a restriction violation is a non-serious error, + -- but we treat violation of No_Finalization as a serious + -- error, since we want to turn off expansion in this case, + -- expansion just causes too many cascaded errors. + + if R = No_Finalization then + Restriction_Msg ("violation of restriction %#", Rimage, N); + else + Restriction_Msg ("|violation of restriction %#", Rimage, N); + end if; end if; -- Otherwise we have the case of an implicit restriction |