================ @@ -1695,6 +1707,12 @@ MallocChecker::processNewAllocation(const CXXAllocatorCall &Call, // MallocUpdateRefState() instead of MallocMemAux() which breaks the // existing binding. SVal Target = Call.getObjectUnderConstruction(); + if (Call.getOriginExpr()->isArray()) { + std::optional<const Expr *> SizeEx = NE->getArraySize(); + if (SizeEx) ---------------- steakhal wrote:
```suggestion if (auto SizeEx = NE->getArraySize()) ``` https://github.com/llvm/llvm-project/pull/92420 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits