diff options
author | Jordan Rose <jordan_rose@apple.com> | 2013-01-19 19:52:57 +0000 |
---|---|---|
committer | Jordan Rose <jordan_rose@apple.com> | 2013-01-19 19:52:57 +0000 |
commit | 2b9de0bc05e3e1092a9d1880e62aeaa54dc343e3 (patch) | |
tree | 6064987407dec6cca6bf12bd3f5fd334dbaddb78 /lib | |
parent | e8d7514d6adc149126d5cd47df95600389f0cb70 (diff) |
[analyzer] Don't show "Entered 'foo'" if 'foo' is implicit.
Before:
Calling implicit default constructor for 'Foo' (where Foo is constructed)
Entered call from 'test' (at "=default" or 'Foo' declaration)
Calling default constructor for 'Bar' (at "=default" or 'Foo' declaration)
After:
Calling implicit default constructor for 'Foo' (where Foo is constructed)
Calling default constructor for 'Bar' (at "=default" or 'Foo' declaration)
This only affects the plist diagnostics; this note is never shown in the
other diagnostics.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172915 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/StaticAnalyzer/Core/PathDiagnostic.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/StaticAnalyzer/Core/PathDiagnostic.cpp b/lib/StaticAnalyzer/Core/PathDiagnostic.cpp index a584a84eea..3c6ff6cac6 100644 --- a/lib/StaticAnalyzer/Core/PathDiagnostic.cpp +++ b/lib/StaticAnalyzer/Core/PathDiagnostic.cpp @@ -877,6 +877,11 @@ IntrusiveRefCntPtr<PathDiagnosticEventPiece> PathDiagnosticCallPiece::getCallEnterWithinCallerEvent() const { if (!callEnterWithin.asLocation().isValid()) return 0; + if (Callee->isImplicit()) + return 0; + if (const CXXMethodDecl *MD = dyn_cast<CXXMethodDecl>(Callee)) + if (MD->isDefaulted()) + return 0; SmallString<256> buf; llvm::raw_svector_ostream Out(buf); |