2015-11-12 Arnaud Charlet <charlet@adacore.com>
* switch-c.adb, gnat1drv.adb, opt.ads: Reserve -gnateg for generation
of C headers.
From-SVN: r230248
+2015-11-12 Arnaud Charlet <charlet@adacore.com>
+
+ * switch-c.adb, gnat1drv.adb, opt.ads: Reserve -gnateg for generation
+ of C headers.
+
2015-11-12 Arnaud Charlet <charlet@adacore.com>
* back_end.adb, opt.ads (Debugger_Level): Update comment.
Modify_Tree_For_C := True;
end if;
- -- Set all flags required when generating C code (-gnatd.V)
+ -- -gnatd.V enables C generation
if Debug_Flag_Dot_VV then
Generate_C_Code := True;
+ end if;
+
+ -- Set all flags required when generating C code
+
+ if Generate_C_Code then
Modify_Tree_For_C := True;
Unnest_Subprogram_Mode := True;
Generate_C_Code : Boolean := False;
-- GNAT
-- If True, the Cprint circuitry to generate C code output is activated.
- -- Set True by use of -gnatd.V.
+ -- Set True by use of -gnateg or -gnatd.V.
Generate_CodePeer_Messages : Boolean := False;
-- GNAT
Ptr := Ptr + 1;
Check_Float_Overflow := not Machine_Overflows_On_Target;
+ -- -gnateg (generate C code)
+
+ when 'g' =>
+ Generate_C_Code := True;
+ Ptr := Ptr + 1;
+
-- -gnateG (save preprocessor output)
when 'G' =>