efriedma-quic wrote:

So the idea here is that if the struct in question uses counted_by, you 
automatically set the count... and if, for whatever reason, the compiler can't 
find the corresponding field, you just throw away the count?  That seems like 
an terrifying API; it's impossible to predict what it will do with a given bit 
of code.

Maybe it makes sense to return null if you find the field, but it doesn't have 
a counted_by attribute at all.  But there should still be diagnostics for all 
the other failure modes.

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

Reply via email to