================

----------------
rapidsna wrote:

> This should be fine, because count is declared before use—unless I'm getting 
> type attributes confused with field attributes..

`struct size_unknown *__counted_by(count) buf` indicates that `buf` has 
`sizeof(struct size_unknown) * count` bytes. So the problem is here that the 
compiler doesn't know what's the actual byte size of `buf` because 
`sizeof(struct unknown_size)` is not available here.

https://github.com/llvm/llvm-project/pull/87596
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to