diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-11-30 16:08:37 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-11-30 16:08:37 +0000 |
commit | d36a3269d0e6c5b34a0cf85c75e416186176b01d (patch) | |
tree | 9fe7bb7e1792a568a310d0ca746ddff32e9cb8b8 /gcc/ada/sem_util.adb | |
parent | f648ee3f0265eb917e18fca4383aff5c08207c72 (diff) | |
download | gcc-d36a3269d0e6c5b34a0cf85c75e416186176b01d.tar.gz |
2009-11-30 Matthew Heaney <heaney@adacore.com>
* a-coinve.adb (Insert): Move exception handler closer to point where
exception can occur.
Minor reformatting & comment additions.
2009-11-30 Arnaud Charlet <charlet@adacore.com>
* freeze.adb (Freeze_Entity): Disable warning on 'Foreign caller must
pass bounds' for VM targets, not relevant.
2009-11-30 Robert Dewar <dewar@adacore.com>
* sem_util.adb (Wrong_Type): Diagnose additional case of modular
missing parens.
* a-tiinio.adb, a-wtinio.adb, a-ztinio.adb: Minor reformatting
* exp_util.adb (Kill_Dead_Code): Suppress warning for some additional
cases.
* sem_warn.adb (Set_Warning_Flag): Clean up gnatwA list and ensure
completeness.
(Set_Dot_Warning_Flag): Ditto for -gnatw.e
(Set_Dot_Warning_Flag): Implement -gnbatw.v/w.V
* usage.adb: Add lines for -gnatw.v/w.V
2009-11-30 Emmanuel Briot <briot@adacore.com>
* make.adb (Check_Standard_Library): use Full_Source_Name instead of
direct call to Find_File. The former provides caching of the results, so
might be more efficient
(Start_Compile_If_Necessary): Add comment on possible optimization,
not done for now.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@154825 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/sem_util.adb')
-rw-r--r-- | gcc/ada/sem_util.adb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ada/sem_util.adb b/gcc/ada/sem_util.adb index a73d346084a..e56066b7d4d 100644 --- a/gcc/ada/sem_util.adb +++ b/gcc/ada/sem_util.adb @@ -11380,7 +11380,15 @@ package body Sem_Util is L : constant Node_Id := Left_Opnd (Op); R : constant Node_Id := Right_Opnd (Op); begin - if Etype (L) = Found_Type + -- The case for the message is when the left operand of the + -- comparison is the same modular type, or when it is an + -- integer literal (or other universal integer expression), + -- which would have been typed as the modular type if the + -- parens had been there. + + if (Etype (L) = Found_Type + or else + Etype (L) = Universal_Integer) and then Is_Integer_Type (Etype (R)) then Error_Msg_N |