From b8b2ed6529f176db7832d1e2a69fae55fa336bc8 Mon Sep 17 00:00:00 2001 From: Richard Smith Date: Thu, 23 Apr 2015 18:18:26 +0000 Subject: [modules] Determine the set of macros exported by a submodule at the end of that submodule. Previously we'd defer this determination until writing the AST, which doesn't allow us to use this information when building other submodules of the same module. This change also allows us to use a uniform mechanism for writing module macro records, independent of whether they are local or imported. llvm-svn: 235614 --- clang/lib/Lex/Preprocessor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clang/lib/Lex/Preprocessor.cpp') diff --git a/clang/lib/Lex/Preprocessor.cpp b/clang/lib/Lex/Preprocessor.cpp index 51a038ac728..6f2e390fc03 100644 --- a/clang/lib/Lex/Preprocessor.cpp +++ b/clang/lib/Lex/Preprocessor.cpp @@ -322,7 +322,7 @@ StringRef Preprocessor::getLastMacroWithSpelling( for (Preprocessor::macro_iterator I = macro_begin(), E = macro_end(); I != E; ++I) { const MacroDirective::DefInfo - Def = I->second->findDirectiveAtLoc(Loc, SourceMgr); + Def = I->second.findDirectiveAtLoc(Loc, SourceMgr); if (!Def || !Def.getMacroInfo()) continue; if (!Def.getMacroInfo()->isObjectLike()) -- cgit v1.2.3