[Libreoffice-commits] core.git: compilerplugins/clang
Stephan Bergmann
sbergman at redhat.com
Tue May 5 05:16:50 PDT 2015
compilerplugins/clang/vclwidgets.cxx | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
New commits:
commit d879d5346b525c478e93363b7ec06e797ce01461
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Tue May 5 14:16:08 2015 +0200
Downgrade for old Clang
Change-Id: Ia4c241040c52631df86c5bb7a95bca6af234251f
diff --git a/compilerplugins/clang/vclwidgets.cxx b/compilerplugins/clang/vclwidgets.cxx
index d239c67..e7066c2 100644
--- a/compilerplugins/clang/vclwidgets.cxx
+++ b/compilerplugins/clang/vclwidgets.cxx
@@ -150,7 +150,9 @@ bool VCLWidgets::VisitCXXDestructorDecl(const CXXDestructorDecl* pCXXDestructorD
return true;
}
bool foundVclPtrField = false;
- for(auto fieldDecl : pRecordDecl->fields()) {
+ for(auto fieldDecl = pRecordDecl->field_begin();
+ fieldDecl != pRecordDecl->field_end(); ++fieldDecl)
+ {
const RecordType *pFieldRecordType = fieldDecl->getType()->getAs<RecordType>();
if (pFieldRecordType) {
const CXXRecordDecl *pFieldRecordTypeDecl = dyn_cast<CXXRecordDecl>(pFieldRecordType->getDecl());
@@ -161,7 +163,9 @@ bool VCLWidgets::VisitCXXDestructorDecl(const CXXDestructorDecl* pCXXDestructorD
}
}
bool foundDispose = false;
- for(auto methodDecl : pRecordDecl->methods()) {
+ for(auto methodDecl = pRecordDecl->method_begin();
+ methodDecl != pRecordDecl->method_end(); ++methodDecl)
+ {
if (methodDecl->isInstance() && methodDecl->param_size()==0 && methodDecl->getNameAsString() == "dispose") {
foundDispose = true;
break;
@@ -303,7 +307,9 @@ bool VCLWidgets::VisitFieldDecl(const FieldDecl * fieldDecl) {
&& startsWith(recordDecl->getQualifiedNameAsString(), "VclPtr"))
{
bool foundDispose = false;
- for(auto methodDecl : pParentRecordDecl->methods()) {
+ for(auto methodDecl = pParentRecordDecl->method_begin();
+ methodDecl != pParentRecordDecl->method_end(); ++methodDecl)
+ {
if (methodDecl->isInstance() && methodDecl->param_size()==0 && methodDecl->getNameAsString() == "dispose") {
foundDispose = true;
break;
More information about the Libreoffice-commits
mailing list