================
@@ -321,12 +321,27 @@ bool 
CallAndMessageChecker::uninitRefOrPointer(CheckerContext &C, SVal V,
   const SVal PointeeV = State->getSVal(SValMemRegion, PointeeT);
   const Expr *ArgEx = Call.getArgExpr(ArgumentNumber);
 
+  auto DescribeArgument = [ParamT, PointeeT,
+                           &Call](bool ArgIsStruct) -> std::string {
+    if (PointeeT.isConstQualified())
+      return llvm::formatv(
+          "This argument is const{0} and {1} input data of the function",
+          ParamT->isPointerType() ? " pointer" : "",
+          ArgIsStruct ? "may contain" : "is likely");
+    else
+      return llvm::formatv(
+          "Function '{0}' expects {1}this argument to be initialized",
----------------
NagyDonat wrote:

```suggestion
          "function '{0}' expects {1}this argument to be initialized",
```

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

Reply via email to