Re: [PATCH] __atomic error reporting

2011-11-24 Thread Joseph S. Myers
On Thu, 24 Nov 2011, Andrew MacLeod wrote: > On 11/22/2011 04:20 PM, Joseph S. Myers wrote: > > * If TYPE_SIZE_UNIT if the pointer target type is zero. This could be the > > case for empty structures or zero-size arrays (both GNU extensions). > > Logically there's nothing wrong with atomic operat

Re: [PATCH] __atomic error reporting

2011-11-24 Thread Andrew MacLeod
On 11/22/2011 04:20 PM, Joseph S. Myers wrote: * If TYPE_SIZE_UNIT if the pointer target type is zero. This could be the case for empty structures or zero-size arrays (both GNU extensions). Logically there's nothing wrong with atomic operations on such a zero-size object (they should evaluate al

Re: [PATCH] __atomic error reporting

2011-11-22 Thread Joseph S. Myers
On Tue, 22 Nov 2011, Andrew MacLeod wrote: > int n = get_atomic_generic_size (loc, function, params); > > + /* Size of 0 is an error condition. */ > + if (n == 0) > + { > + *new_return = error_mark_node; > + return true; > + } As far as I can see, get_atomic_generi