Kaydet (Commit) 5c142dd3 authored tarafından Noel Grandin's avatar Noel Grandin

loplugin:mergeclass, fix and update results

Change-Id: I0660833db69604c5c4dd3c5826f1baac3086e052
üst 266abd09
...@@ -120,11 +120,12 @@ bool MergeClasses::VisitCXXConstructExpr( const CXXConstructExpr* pCXXConstructE ...@@ -120,11 +120,12 @@ bool MergeClasses::VisitCXXConstructExpr( const CXXConstructExpr* pCXXConstructE
if (ignoreLocation(pCXXConstructExpr)) { if (ignoreLocation(pCXXConstructExpr)) {
return true; return true;
} }
const CXXConstructorDecl* pCXXConstructorDecl = pCXXConstructExpr->getConstructor(); // ignore calls when a sub-class is constructing it's superclass
const CXXRecordDecl* pParentCXXRecordDecl = pCXXConstructorDecl->getParent(); if (pCXXConstructExpr->getConstructionKind() != CXXConstructExpr::ConstructionKind::CK_Complete) {
if (ignoreLocation(pParentCXXRecordDecl)) {
return true; return true;
} }
const CXXConstructorDecl* pCXXConstructorDecl = pCXXConstructExpr->getConstructor();
const CXXRecordDecl* pParentCXXRecordDecl = pCXXConstructorDecl->getParent();
std::string s = pParentCXXRecordDecl->getQualifiedNameAsString(); std::string s = pParentCXXRecordDecl->getQualifiedNameAsString();
addToInstantiatedSet(s); addToInstantiatedSet(s);
return true; return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment