forked from OSchip/llvm-project
Fixed a bug in building ctor-initializer AST.
llvm-svn: 75692
This commit is contained in:
parent
bb0d9a5129
commit
5da7ecb245
|
@ -496,7 +496,7 @@ CXXConstructorDecl::setBaseOrMemberInitializers(
|
||||||
for (i = 0; i < NumInitializers; i++) {
|
for (i = 0; i < NumInitializers; i++) {
|
||||||
CXXBaseOrMemberInitializer *Member = Initializers[i];
|
CXXBaseOrMemberInitializer *Member = Initializers[i];
|
||||||
if (Member->isBaseInitializer() &&
|
if (Member->isBaseInitializer() &&
|
||||||
Member->getBaseClass() == T) {
|
Member->getBaseClass()->getAsRecordType() == T) {
|
||||||
AllToInit.push_back(Member);
|
AllToInit.push_back(Member);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -517,7 +517,8 @@ CXXConstructorDecl::setBaseOrMemberInitializers(
|
||||||
unsigned int i = 0;
|
unsigned int i = 0;
|
||||||
for (i = 0; i < NumInitializers; i++) {
|
for (i = 0; i < NumInitializers; i++) {
|
||||||
CXXBaseOrMemberInitializer *Member = Initializers[i];
|
CXXBaseOrMemberInitializer *Member = Initializers[i];
|
||||||
if (Member->isBaseInitializer() && Member->getBaseClass() == T) {
|
if (Member->isBaseInitializer() &&
|
||||||
|
Member->getBaseClass()->getAsRecordType() == T) {
|
||||||
AllToInit.push_back(Member);
|
AllToInit.push_back(Member);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue