I've seen in the ISO C99 committee draft that structs can have an incomplete an array with unspecified size its end, known as Flexible Array Member.
On the other hand C99 also has Variable Length Arrays, which allow declaring arrays with size not constant at compile-time.
I thought that a FAM was a special kind of a VLA, but I've seen two SO users claiming otherwise. Also, reading the Wikipedia section on sizeof
, it says that sizeof
behaves differently for those two.
Why do both of them exist instead of just one? (Are their use-cases too different?)
Also, which other associated behaviors are different for each of them?