You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Flexible arrays are arrays declared without a specific size, e.g:
uint8_t my_array[];
They are widely used as as last member in structs that are dynamically
allocated.
Since C99 they are part of the C standard, but for historical reasons
many places still use an older GNU extension that is declare zero
length arrays.
Although zero length arrays are flexible arrays, we can't blindly
replace [0] with [] because of some syntax limitations. This macro
workaround these limitations while get rid of this non standard
extension.
Using true flexible arrays allows the compiler to calculate the size
of the array better and improve potential issue checking.
Signed-off-by: Flavio Ceolin <[email protected]>
0 commit comments