https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63233

--- Comment #6 from Mikael Pettersson <mikpelinux at gmail dot com> ---
(In reply to leis from comment #5)
> Fundamentally, what I'm really trying to do, is to have two arrays (of
> different types) in a fixed-sized struct. One array grows from the front,
> and one from the end. Dynamically I make sure that they do not overlap, but
> the sizes of the two arrays are not known statically. Is it really violating
> the standard?

Something like

union u {
  int a[50];
  char b[50 * sizeof int];
};

and accessing one array with incrementing indices and the other with
decrementing indices should work, if I understand your problem statement
correctly.  But this is now about programming not a gcc bug, so please use
gcc-help or some general C programming forum instead.

Reply via email to