You have to call setHasLoadedFieldsFromExternalStorage AFTER calling

the field_begin that starts the copy or it won't do anything.

This causes failures, but only in complex apps, I haven't found
a reduced test case for this yet. 

<rdar://problem/21951798>

llvm-svn: 268467
This commit is contained in:
Jim Ingham 2016-05-04 00:06:23 +00:00
parent c826e634cc
commit c44644d6e9
1 changed files with 1 additions and 1 deletions

View File

@ -2618,8 +2618,8 @@ GetCompleteQualType (clang::ASTContext *ast, clang::QualType qual_type, bool all
external_ast_source->CompleteType(cxx_record_decl);
if (cxx_record_decl->isCompleteDefinition())
{
cxx_record_decl->setHasLoadedFieldsFromExternalStorage (true);
cxx_record_decl->field_begin();
cxx_record_decl->setHasLoadedFieldsFromExternalStorage (true);
}
}
}