[clang] [clang][ExprConst] Let diagnostics point to std::allocator calls (PR #123744)
Timm Baeder via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 22 21:15:22 PST 2025
================
@@ -1155,7 +1156,7 @@ namespace {
if (CTSD->isInStdNamespace() && ClassII &&
ClassII->isStr("allocator") && TAL.size() >= 1 &&
TAL[0].getKind() == TemplateArgument::Type)
- return {Call->Index, TAL[0].getAsType()};
+ return {Call->Index, TAL[0].getAsType(), Call->CallExpr};
}
return {};
----------------
tbaederr wrote:
All callers of `getStdAllocatorCaller()` check that the returned value converts to `true`, and `Call` can't be`nullptr` if that's the case.
https://github.com/llvm/llvm-project/pull/123744
More information about the cfe-commits
mailing list