vbvictor wrote:
Hi, thank you for the proposal! Have you read similar thread in
https://discourse.llvm.org/t/rfc-add-a-class-attribute-clang-null-after-move-for-use-after-move-analysis/89760?
I think from clang side, new annotation that is used only for analysis will be
rejected due to very narrow scope.
I think we can reuse `clang::annotate` for this case and make something like:
```cpp
[[clang::annotate("analyze_as_class", "optional")]]
[[clang::annotate("analyze_as_method", "std::optional::has_value")]]
```
Or if we with to be more verbose and specific (up to discussion):
```cpp
[[clang::annotate("clang-tidy", "analyze_as_class", "optional")]]
[[clang::annotate("clang-tidy", "analyze_as_method", "optional::has_value")]]
```
https://github.com/llvm/llvm-project/pull/195054
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits