[clang] [analyzer] Add cplusplus.DestroyedAsWrongType checker (PR #237801)
Donát Nagy via cfe-commits
cfe-commits at lists.llvm.org
Thu Nov 5 13:46:16 PST 2026
https://github.com/NagyDonat commented:
Thanks for the updates!
I added some new stylistic nitpicks; but I'm still very impressed by the code quality. (Even the only non-nitpick suggestion https://github.com/llvm/llvm-project/pull/237801#discussion_r4442775992 from my first review round turned out to be my mistake 😅.)
----
> > However, I think it would be nice if the diagnostic message would indicate that the destructor is called indirectly, through a standard library utility. [...]
> Reports deferred out of std now name the function that made the call, [...]
Good job, thanks for implementing it!
> > > explicit non-virtual base class destructor call on a derived object is reported, although [class.dtor]/16 allows it.
> >
> > What was the obstacle to following the standard in this case?
>
> Basically, there was no obstacle.
Nice solution! Don't forget to remove the limitation from the PR description ;)
https://github.com/llvm/llvm-project/pull/237801
More information about the cfe-commits
mailing list