Change a dyn_cast_or_null back to cast (which is more efficient).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@43152
91177308-0d34-0410-b5e6-
96231b3b80d8
IdentifierInfo *VaIdent = &Context.Idents.get("__builtin_va_list");
ScopedDecl *VaDecl = LookupScopedDecl(VaIdent, Decl::IDNS_Ordinary,
SourceLocation(), TUScope);
- TypedefDecl *VaTypedef = dyn_cast_or_null<TypedefDecl>(VaDecl);
+ TypedefDecl *VaTypedef = cast<TypedefDecl>(VaDecl);
Context.setBuiltinVaListType(Context.getTypedefType(VaTypedef));
}
ScopedDecl *IFace = LookupScopedDecl(NSIdent, Decl::IDNS_Ordinary,
SourceLocation(), TUScope);
ObjcInterfaceDecl *strIFace = dyn_cast_or_null<ObjcInterfaceDecl>(IFace);
- assert(strIFace && "missing '@interface NSConstantString'");
+ assert(strIFace && "missing @interface for NSConstantString"
+ "FIXME: need to predefine without breaking explicit inclusion");
Context.setObjcConstantStringInterface(strIFace);
}
QualType t = Context.getObjcConstantStringInterface();