================
@@ -29,7 +29,6 @@ void TestStringViewTypes(custom::StrView sv) {
void TestAllowedCallees(custom::StrView sv) {
safe_func(sv.data());
SafeClass sc(sv.data());
- // CHECK-MESSAGES: :[[@LINE-1]]:19: warning: result of a `data()` call may
not be null terminated, provide size information to the callee to prevent
potential issues [bugprone-suspicious-stringview-data-usage]
----------------
zeyi2 wrote:
This seems like an pre-existing issue:
The [`AllowedCallees`
documentation](https://clang.llvm.org/extra/clang-tidy/checks/bugprone/suspicious-stringview-data-usage.html#cmdoption-arg-AllowedCallees)
explicitly includes classes among the entities that can be excluded. Since
this test lists the `SafeClass`, its constructor call should not produce a
diagnostic once special declaration names are matched correctly. So I think
this diagnostic expectation should be removed.
https://github.com/llvm/llvm-project/pull/230353
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits