aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/adabkend.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2014-08-04 14:51:00 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2014-08-04 14:51:00 +0200
commit51dcceecdf58128ea13fede4507327a3f8595804 (patch)
treed7af2bc049447bc647f5bff8d75144874d2eba8d /gcc/ada/adabkend.adb
parentdf9107226f53d4ba405c2fb4c5d5c9ee2aaaec1f (diff)
downloadgcc-51dcceecdf58128ea13fede4507327a3f8595804.zip
gcc-51dcceecdf58128ea13fede4507327a3f8595804.tar.gz
gcc-51dcceecdf58128ea13fede4507327a3f8595804.tar.bz2
[multiple changes]
2014-08-04 Hristian Kirtchev <kirtchev@adacore.com> * sem_prag.adb (Analyze_Pragma): Ensure that an internally generated spec for a stand alone body is recognized as a proper context for pragma SPARK_Mode. 2014-08-04 Robert Dewar <dewar@adacore.com> * erroutc.adb (Delete_Msg): Do not decrement Warnings_Treated_As_Errors. 2014-08-04 Arnaud Charlet <charlet@adacore.com> * adabkend.adb (Scan_Back_End_Switches): Ignore extra -o when -gnatO has already been specified, for compatibility with gcc driver. (Scan_Compiler_Args): Do not call Set_Output_Object_File_Name in codepeer mode. * g-expect.ads: Fix typo. 2014-08-04 Thomas Quinot <quinot@adacore.com> * exp_ch4.adb (Insert_Dereference_Action): the actual Size must account for the bounds template if the designated type is an unconstrained array. From-SVN: r213579
Diffstat (limited to 'gcc/ada/adabkend.adb')
-rw-r--r--gcc/ada/adabkend.adb20
1 files changed, 15 insertions, 5 deletions
diff --git a/gcc/ada/adabkend.adb b/gcc/ada/adabkend.adb
index 1e1a2d9..1a42000 100644
--- a/gcc/ada/adabkend.adb
+++ b/gcc/ada/adabkend.adb
@@ -6,7 +6,7 @@
-- --
-- B o d y --
-- --
--- Copyright (C) 2001-2013, AdaCore --
+-- Copyright (C) 2001-2014, AdaCore --
-- --
-- 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- --
@@ -108,7 +108,16 @@ package body Adabkend is
elsif Switch_Chars (First .. Last) = "o" then
if First = Last then
- Opt.Output_File_Name_Present := True;
+ if Opt.Output_File_Name_Present then
+
+ -- Ignore extra -o when -gnatO has already been specified
+
+ Next_Arg := Next_Arg + 1;
+
+ else
+ Opt.Output_File_Name_Present := True;
+ end if;
+
return;
else
Fail ("invalid switch: " & Switch_Chars);
@@ -237,10 +246,11 @@ package body Adabkend is
-- In GNATprove_Mode, such an object file is never written, and
-- the call to Set_Output_Object_File_Name may fail (e.g. when
- -- the object file name does not have the expected suffix). So
- -- we skip that call when GNATprove_Mode is set.
+ -- the object file name does not have the expected suffix).
+ -- So we skip that call when GNATprove_Mode is set. Same for
+ -- CodePeer_Mode.
- elsif GNATprove_Mode then
+ elsif GNATprove_Mode or CodePeer_Mode then
Output_File_Name_Seen := True;
else