]> granicus.if.org Git - clang/commit
[analyzer] pr38838, pr39976: Fix crash on diagnosing before implicit destructor.
authorArtem Dergachev <artem.dergachev@gmail.com>
Thu, 10 Jan 2019 23:44:44 +0000 (23:44 +0000)
committerArtem Dergachev <artem.dergachev@gmail.com>
Thu, 10 Jan 2019 23:44:44 +0000 (23:44 +0000)
commit2f9e8fb6b8195fddf0452dadf6a9b6d824bee23c
treebd603b63bdaf0159ab217952f94b25701a8f7f30
parent9cedc71c6c932d740160a10164361882fee406cb
[analyzer] pr38838, pr39976: Fix crash on diagnosing before implicit destructor.

We need to be able to emit the diagnostic at PreImplicitCall,
and the patch implements this functionality.

However, for now the need for emitting such diagnostics is not all that great:
it is only necessary to not crash when emitting a false positive due to an
unrelated issue of having dead symbol collection not working properly.

Coming up with a non-false-positive test seems impossible with the current
set of checkers, though it is likely to be needed for good things as well
in the future.

Differential Revision: https://reviews.llvm.org/D56042

rdar://problem/46911462

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@350907 91177308-0d34-0410-b5e6-96231b3b80d8
lib/StaticAnalyzer/Core/PathDiagnostic.cpp
test/Analysis/diagnostics/dtors.cpp [new file with mode: 0644]