From d52c445118349a7745a8f5679ff7abb67a164f40 Mon Sep 17 00:00:00 2001 From: Alexey Bataev Date: Sat, 11 Oct 2014 05:07:24 +0000 Subject: [PATCH] Fix deserialization of PredefinedExpr in dependent context. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@219561 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Serialization/ASTReaderStmt.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Serialization/ASTReaderStmt.cpp b/lib/Serialization/ASTReaderStmt.cpp index 61e509b254..7a20f7fed0 100644 --- a/lib/Serialization/ASTReaderStmt.cpp +++ b/lib/Serialization/ASTReaderStmt.cpp @@ -423,7 +423,7 @@ void ASTStmtReader::VisitPredefinedExpr(PredefinedExpr *E) { VisitExpr(E); E->setLocation(ReadSourceLocation(Record, Idx)); E->Type = (PredefinedExpr::IdentType)Record[Idx++]; - E->FnName = cast(Reader.ReadSubExpr()); + E->FnName = cast_or_null(Reader.ReadSubExpr()); } void ASTStmtReader::VisitDeclRefExpr(DeclRefExpr *E) { -- 2.40.0