2013-07-05 Robert Dewar <dewar@adacore.com>
+ * gnat_rm.texi: Document that -gnatR and -gnatD cannot be used
+ together.
+ * switch-c.adb: Do not allow -gnatD and -gnatR to both be
+ specified.
+
+2013-07-05 Robert Dewar <dewar@adacore.com>
+
* gnat_rm.texi: Add missing documentation for pragmas.
* sem_ch8.adb: Minor reformatting.
* gnat_ugn.texi: Document that -gnatR and -gnatD cannot be used
* Pragma No_Body::
* Pragma No_Inline::
* Pragma No_Return::
+* Pragma No_Run_Time::
* Pragma No_Strict_Aliasing ::
* Pragma Normalize_Scalars::
* Pragma Obsolescent::
* Pragma No_Body::
* Pragma No_Inline::
* Pragma No_Return::
+* Pragma No_Run_Time::
* Pragma No_Strict_Aliasing::
* Pragma Normalize_Scalars::
* Pragma Obsolescent::
available in all earlier versions of Ada as an implementation-defined
pragma.
+@node Pragma No_Run_Time
+@unnumberedsec Pragma No_Run_Time
+@findex No_Run_Time
+@noindent
+Syntax:
+
+@smallexample @c ada
+pragma No_Run_Time;
+@end smallexample
+
+@noindent
+This is an obsolete configuration pragma that historically was used to
+setup what is now called the "zero footprint" library. It causes any
+library units outside this basic library to be ignored. The use of
+this pragma has been superceded by the general configuration run-time
+capability of @code{GNAT} where the compiler takes into account whatever
+units happen to be accessible in the library.
+
@node Pragma No_Strict_Aliasing
@unnumberedsec Pragma No_Strict_Aliasing
@findex No_Strict_Aliasing
when 'D' =>
Ptr := Ptr + 1;
+ -- Not allowed if previous -gnatR given
+
+ -- The reason for this prohibition is that the rewriting of
+ -- Sloc values causes strange malfunctions in the tests of
+ -- whether units belong to the main source. This is really a
+ -- bug, but too hard to fix for a marginal capability ???
+
+ -- The proper fix is to completely redo -gnatD processing so
+ -- that the tree is not messed with, and instead a separate
+ -- table is built on the side for debug information generation.
+
+ if List_Representation_Info /= 0 then
+ Osint.Fail
+ ("-gnatD not permitted since -gnatR given previously");
+ end if;
+
-- Scan optional integer line limit value
if Nat_Present (Switch_Chars, Max, Ptr) then
-- -gnatR (list rep. info)
when 'R' =>
+
+ -- Not allowed if previous -gnatD given. See more extensive
+ -- comments in the 'D' section for the inverse test.
+
+ if Debug_Generated_Code then
+ Osint.Fail
+ ("-gnatR not permitted since -gnatD given previously");
+ end if;
+
+ -- Set to annotate rep info, and set default -gnatR mode
+
Back_Annotate_Rep_Info := True;
List_Representation_Info := 1;
+ -- Scan possible parameter
+
Ptr := Ptr + 1;
while Ptr <= Max loop
C := Switch_Chars (Ptr);