From: Richard Smith Date: Mon, 4 May 2015 19:58:00 +0000 (+0000) Subject: [modules] Don't bother registering loaded macros if there are none. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=c2d6540aeb6729afe11498e746a10fde0a9bc7d0;p=clang [modules] Don't bother registering loaded macros if there are none. We don't yet have a reduced testcase for this. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@236454 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Serialization/ASTReader.cpp b/lib/Serialization/ASTReader.cpp index 0dd9d2e460..c4b4aec24a 100644 --- a/lib/Serialization/ASTReader.cpp +++ b/lib/Serialization/ASTReader.cpp @@ -1829,7 +1829,8 @@ void ASTReader::resolvePendingMacro(IdentifierInfo *II, Earliest = MD; } - PP.setLoadedMacroDirective(II, Latest); + if (Latest) + PP.setLoadedMacroDirective(II, Latest); } ASTReader::InputFileInfo