2011-11-04 Robert Dewar <dewar@adacore.com>
+ * sem_prag.adb: Minor reformatting.
+ * gnat_rm.texi: Update documentation for pragma Warnings (Off,
+ "***") usage.
+ * exp_ch2.adb (Expand_Entity_Reference): Only set
+ Atomic_Sync_Required on entities that are variables. Doesn't
+ make any sense on anything else.
+
+2011-11-04 Robert Dewar <dewar@adacore.com>
+
* exp_ch2.adb (Expand_Entity_Reference): Extend handling of
atomic sync to type case.
* sem_prag.adb (Process_Suppress_Unsuppress): Atomic Sync can
modifies this set of warnings as specified. This form of the pragma may
also be used as a configuration pragma.
-The fourth form, with an On|Off parameter and a string, is used to
+The fourth form, with an @code{On|Off} parameter and a string, is used to
control individual messages, based on their text. The string argument
is a pattern that is used to match against the text of individual
warning messages (not including the initial "warning: " tag).
expression notations are permitted. All characters other than asterisk in
these three specific cases are treated as literal characters in the match.
-There are two ways to use this pragma. The OFF form can be used as a
+There are two ways to use the pragma in this form. The OFF form can be used as a
configuration pragma. The effect is to suppress all warnings (if any)
that match the pattern string throughout the compilation.
In this usage, the pattern string must match in the Off and On pragmas,
and at least one matching warning must be suppressed.
+Note: to write a string that will match any warning, use the string
+@code{"***"}. It will not work to use a single asterisk or two asterisks
+since this looks like an operator name. This form with three asterisks
+is similar in effect to specifying @code{pragma Warnings (Off)} except that a
+matching @code{pragma Warnings (On, "***")} will be required. This can be
+helpful in avoiding forgetting to turn warnings back on.
+
Note: the debug flag -gnatd.i (@code{/NOWARNINGS_PRAGMAS} in VMS) can be
used to cause the compiler to entirely ignore all WARNINGS pragmas. This can
be useful in checking whether obsolete pragmas in existing programs are hiding