I stumbled on the below code which has been confusing me:
union
{
struct
{
uint32_t Id;
uint8_t a_data[];
}vendor;
uint8_t avp[0];
}data;
This compiles fine with g++ 7.2.1, but I'm not able to understand why. How is there no need to provide the size while defining a_data? How can avp have size zero?