Re: [PATCH][next] bcachefs: Replace zero-length arrays with flexible-array members

From: Kent Overstreet
Date: Wed Nov 29 2023 - 16:13:08 EST


On Tue, Nov 28, 2023 at 12:22:55PM -0600, Gustavo A. R. Silva wrote:
> Fake flexible arrays (zero-length and one-element arrays) are
> deprecated, and should be replaced by flexible-array members.
>
> So, replace zero-length arrays with flexible-array members
> in multiple structures.
>
> Signed-off-by: Gustavo A. R. Silva <gustavoars@xxxxxxxxxx>

There are some ZLAs I hadn't converted because they led to new warnings
- in particular, array of flexible members.

I don't think that applies to any of the ones you changed
(replicas_delta_list, maybe?) - but it's something we need to figure
out if we're getting serious about this.