[Ada] Don't allow REASON parameter for pragma Warnings in compiler unit
Arnaud Charlet
charlet@adacore.com
Tue Sep 10 15:21:00 GMT 2013
This patch forbids the use of the pragma Warnings REASON parameter in
compiler units (since this would cause bootstrap issues). This is for
internal development purposes only. No functionality change.
Tested on x86_64-pc-linux-gnu, committed on trunk
2013-09-10 Robert Dewar <dewar@adacore.com>
* sem_prag.adb (Analyze_Pragma, case Warnings): Don't allow
REASON parameter in compiler units (bootstrap issues).
-------------- next part --------------
Index: sem_prag.adb
===================================================================
--- sem_prag.adb (revision 202462)
+++ sem_prag.adb (working copy)
@@ -17958,6 +17958,10 @@
then
Check_Arg_Is_Static_Expression (Last_Arg, Standard_String);
Arg_Count := Arg_Count - 1;
+
+ -- Not allowed in compiler units (bootstrap issues)
+
+ Check_Compiler_Unit (N);
end if;
end;
More information about the Gcc-patches
mailing list