[PATCH] Fix to PR5683 - issue diagnostic for pointer subtraction with type of size zero.
sepavloff at gmail.com
Tue Apr 9 06:46:10 PDT 2013
I've changed the check as you recommended before.
2013/4/9 Richard Smith <richard at metafoo.co.uk>:
> This check still looks wrong to me. CodeGen has special cases for VLAs,
> void, and function types; any other zero-size type should get a diagnostic.
> Right now, it looks like you're missing at least the case of an array with a
> zero-sized element type (such as an array of empty records). I think that's
> the only other case for GNU C, but Objective-C might add some more
Yes, array of empty records is another king of zero-size object, which I missed.
As for Objective-C, I couldn't invent something new...
More information about the cfe-commits