================
@@ -71,7 +71,8 @@ void DanglingPtrDeref::reportUseAfterScope(const MemRegion
*Region,
CheckerContext &C) const {
auto BR = std::make_unique<PathSensitiveBugReport>(
BugMsg,
- (llvm::Twine("Use of ") + lifetime_modeling::getRegionName(Region) +
+ (llvm::Twine("Use of ") +
+ Region->getDescriptiveName(/*UseQuotes=*/true, /*AllowFallback=*/true) +
" after its lifetime ended."),
N);
----------------
steakhal wrote:
If we hit the fallback case, wouldn't that mean that the warning message would
be messed up?
This would be a regression because in the past it used to fall back on using
"the region".
https://github.com/llvm/llvm-project/pull/214245
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits