diff options
Diffstat (limited to 'gcc/ada/par-ch11.adb')
-rw-r--r-- | gcc/ada/par-ch11.adb | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/gcc/ada/par-ch11.adb b/gcc/ada/par-ch11.adb index 5968b72..928d52d 100644 --- a/gcc/ada/par-ch11.adb +++ b/gcc/ada/par-ch11.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2004 Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2005 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- -- @@ -190,6 +190,16 @@ package body Ch11 is Set_Name (Raise_Node, P_Name); end if; + if Token = Tok_With then + if Ada_Version < Ada_05 then + Error_Msg_SC ("string expression in raise is Ada 2005 extension"); + Error_Msg_SC ("\unit must be compiled with -gnat05 switch"); + end if; + + Scan; -- past WITH + Set_Expression (Raise_Node, P_Expression); + end if; + TF_Semicolon; return Raise_Node; end P_Raise_Statement; |