[Ada] Missing error for invalid atomic component

Eric Botcazou ebotcazou@adacore.com
Wed Oct 26 21:14:00 GMT 2011


The compiler should issue the "atomic access cannot be guaranteed" error twice 
on the attached testcase, but it only issues it for the stand-alone variable.

Fixed thusly, tested on i586-suse-linux, applied on the mainline.


2011-10-26  Eric Botcazou  <ebotcazou@adacore.com>

	* gcc-interface/decl.c (gnat_to_gnu_field): Always check components
	declared as atomic.  Move around conditionally executed code.


2011-10-26  Eric Botcazou  <ebotcazou@adacore.com>

	* gnat.dg/specs/atomic1.ads: New test.


-- 
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-diff
Size: 1441 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20111026/c981c425/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: atomic1.ads
Type: text/x-adasrc
Size: 303 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20111026/c981c425/attachment-0001.bin>


More information about the Gcc-patches mailing list