Assert failure (2)
mgehre opened this issue · 2 comments
mgehre commented
void b() {
struct {
char a;
} c[]{};
c[0].a;
}
Xazax-hun commented
After a quick look the problem might be the following:
We do not track pset for the elements of the array individually, but we have only one pset for the whole array (which has the type array). But we assume, when we reference a field of a pset, the type of the pset needs to be a record. But in this case this is an array. Since we do not want to track each individual elements of the array, I think the best solution would be to add a special case and as long as we have an array, let's get the element type. It should also work for multidimensional arrays.
I wonder if there are other constructs with similar problems, like unions.