https://github.com/usx95 requested changes to this pull request.

This looks great! However, the public/private terminology is misleading. The 
actual distinction isn't about linkage visibility, but about translation unit 
boundaries. While static functions and anonymous namespaces serve as a 
heuristic, the core differentiation is about cross-TU vs intra-TU effects of 
the annotations.

I have no concerns with the functional changes, but I suggest adopting 
CrossTU/IntraTU terminology to better reflect the distinction:

**CrossTU**: Declaration in header, definition in source file

- Annotation must be on the header declaration
- Affects callers in other translation units
- Inference cannot replace these annotations across TU boundaries (even in its 
most powerful form)

**IntraTU**: Declaration and definition in the same file

- Inference can potentially handle these within the same TU
- Lower priority - can be addressed through inference

Suggested diagnostics names: 
`-Wexperimental-lifetime-safety-cross-tu-suggestions` and 
`-Wexperimental-lifetime-safety-intra-tu-suggestions`

https://github.com/llvm/llvm-project/pull/171972
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to