diff options
author | Noel Grandin <noel@peralex.com> | 2015-04-09 08:45:51 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-04-13 09:37:12 +0200 |
commit | 26ec80f47df1b32c5e1ae8c96d597ef8c90fee86 (patch) | |
tree | 11b53e701f50ff170552054ef7d23136cd4710b6 /compilerplugins/clang | |
parent | b5f5a386504e320b022f8609c9c36652ae2d3d18 (diff) |
loplugin:staticmethods
Change-Id: I33a8ca28b0c3bf1c31758d93238e74927bebde9c
Diffstat (limited to 'compilerplugins/clang')
-rw-r--r-- | compilerplugins/clang/staticmethods.cxx | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/compilerplugins/clang/staticmethods.cxx b/compilerplugins/clang/staticmethods.cxx index 5ac9da42f9aa..e59a48f60072 100644 --- a/compilerplugins/clang/staticmethods.cxx +++ b/compilerplugins/clang/staticmethods.cxx @@ -142,7 +142,12 @@ bool StaticMethods::TraverseCXXMethodDecl(const CXXMethodDecl * pCXXMethodDecl) { return true; } - + std::string fqn = aParentName + "::" + pCXXMethodDecl->getNameAsString(); + // only empty on Linux, not on windows + if (fqn == "OleEmbeddedObject::GetVisualRepresentationInNativeFormat_Impl" + || fqn == "OleEmbeddedObject::GetRidOfComponent") { + return true; + } bVisitedThis = false; TraverseStmt(pCXXMethodDecl->getBody()); @@ -152,7 +157,7 @@ bool StaticMethods::TraverseCXXMethodDecl(const CXXMethodDecl * pCXXMethodDecl) report( DiagnosticsEngine::Warning, - "this method can be declared static " + aParentName, + "this method can be declared static " + fqn, pCXXMethodDecl->getCanonicalDecl()->getLocStart()) << pCXXMethodDecl->getCanonicalDecl()->getSourceRange(); return true; |