summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/AST/ASTImporter.cpp2
-rw-r--r--clang/lib/Frontend/PCHReaderDecl.cpp2
-rw-r--r--clang/lib/Frontend/PCHWriterDecl.cpp1
3 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/AST/ASTImporter.cpp b/clang/lib/AST/ASTImporter.cpp
index 8d347d17166..0d8896330c9 100644
--- a/clang/lib/AST/ASTImporter.cpp
+++ b/clang/lib/AST/ASTImporter.cpp
@@ -2026,7 +2026,7 @@ Decl *ASTNodeImporter::VisitObjCIvarDecl(ObjCIvarDecl *D) {
cast<ObjCContainerDecl>(DC),
Loc, Name.getAsIdentifierInfo(),
T, TInfo, D->getAccessControl(),
- BitWidth);
+ BitWidth, D->getSynthesize());
ToIvar->setLexicalDeclContext(LexicalDC);
Importer.Imported(D, ToIvar);
LexicalDC->addDecl(ToIvar);
diff --git a/clang/lib/Frontend/PCHReaderDecl.cpp b/clang/lib/Frontend/PCHReaderDecl.cpp
index c8851a7ecc0..e494f7c9345 100644
--- a/clang/lib/Frontend/PCHReaderDecl.cpp
+++ b/clang/lib/Frontend/PCHReaderDecl.cpp
@@ -378,6 +378,8 @@ void PCHDeclReader::VisitObjCInterfaceDecl(ObjCInterfaceDecl *ID) {
void PCHDeclReader::VisitObjCIvarDecl(ObjCIvarDecl *IVD) {
VisitFieldDecl(IVD);
IVD->setAccessControl((ObjCIvarDecl::AccessControl)Record[Idx++]);
+ bool synth = Record[Idx++];
+ IVD->setSynthesize(synth);
}
void PCHDeclReader::VisitObjCProtocolDecl(ObjCProtocolDecl *PD) {
diff --git a/clang/lib/Frontend/PCHWriterDecl.cpp b/clang/lib/Frontend/PCHWriterDecl.cpp
index bc4452ed7f4..64875521c16 100644
--- a/clang/lib/Frontend/PCHWriterDecl.cpp
+++ b/clang/lib/Frontend/PCHWriterDecl.cpp
@@ -363,6 +363,7 @@ void PCHDeclWriter::VisitObjCIvarDecl(ObjCIvarDecl *D) {
VisitFieldDecl(D);
// FIXME: stable encoding for @public/@private/@protected/@package
Record.push_back(D->getAccessControl());
+ Record.push_back(D->getSynthesize());
Code = pch::DECL_OBJC_IVAR;
}
OpenPOWER on IntegriCloud