diff options
author | Douglas Gregor <dgregor@apple.com> | 2011-08-12 06:17:30 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2011-08-12 06:17:30 +0000 |
commit | 52e02808c573630e84e4cdd8548e22193dea3aca (patch) | |
tree | b18861517d17812e5a77d8eac9c6de3047c58ff3 /clang/lib/Serialization/ASTReader.cpp | |
parent | 0300d88af5db80e77ace53fbc40c8a53e5adbd55 (diff) | |
download | bcm5719-llvm-52e02808c573630e84e4cdd8548e22193dea3aca.tar.gz bcm5719-llvm-52e02808c573630e84e4cdd8548e22193dea3aca.zip |
Switch the Objective-C 'SEL' type over to a predefined type in the
AST file format, lazily generating the actual declaration in
ASTContext as needed.
llvm-svn: 137434
Diffstat (limited to 'clang/lib/Serialization/ASTReader.cpp')
-rw-r--r-- | clang/lib/Serialization/ASTReader.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/clang/lib/Serialization/ASTReader.cpp b/clang/lib/Serialization/ASTReader.cpp index 2d4cde05a9d..c048f58fdba 100644 --- a/clang/lib/Serialization/ASTReader.cpp +++ b/clang/lib/Serialization/ASTReader.cpp @@ -2987,11 +2987,6 @@ void ASTReader::InitializeContext(ASTContext &Ctx) { GetType(SpecialTypes[SPECIAL_TYPE_BUILTIN_VA_LIST])); } - if (unsigned Sel = SpecialTypes[SPECIAL_TYPE_OBJC_SELECTOR]) { - if (Context->ObjCSelTypedefType.isNull()) - Context->ObjCSelTypedefType = GetType(Sel); - } - if (unsigned Proto = SpecialTypes[SPECIAL_TYPE_OBJC_PROTOCOL]) { if (Context->ObjCProtoType.isNull()) Context->ObjCProtoType = GetType(Proto); @@ -4220,6 +4215,10 @@ Decl *ASTReader::GetDecl(DeclID ID) { assert(Context && "No context available?"); return Context->getObjCIdDecl(); + case PREDEF_DECL_OBJC_SEL_ID: + assert(Context && "No context available?"); + return Context->getObjCSelDecl(); + case PREDEF_DECL_OBJC_CLASS_ID: assert(Context && "No context available?"); return Context->getObjCClassDecl(); |