Lines Matching refs:PP
35 Preprocessor &PP, raw_ostream &OS) { in PrintMacroDefinition() argument
70 OS << PP.getSpelling(T, SpellingBuffer); in PrintMacroDefinition()
80 Preprocessor &PP; member in __anon46d24f460111::PrintPPOutputPPCallbacks
109 : PP(pp), SM(PP.getSourceManager()), ConcatInfo(PP), OS(os), in PrintPPOutputPPCallbacks()
406 const std::string TokenText = PP.getSpelling(IncludeTok); in InclusionDirective()
423 << "#" << PP.getSpelling(IncludeTok) << " " in InclusionDirective()
481 SourceManager &SM = PP.getSourceManager(); in MacroDefined()
487 PrintMacroDefinition(*MacroNameTok.getIdentifierInfo(), *MI, PP, OS); in MacroDefined()
761 void HandlePragma(Preprocessor &PP, PragmaIntroducer Introducer, in HandlePragma()
774 PP.EnterTokenStream(std::move(Toks), /*NumToks=*/1, in HandlePragma()
777 PP.Lex(PragmaTok); in HandlePragma()
786 std::string TokSpell = PP.getSpelling(PragmaTok); in HandlePragma()
791 PP.Lex(PragmaTok); in HandlePragma()
793 PP.LexUnexpandedToken(PragmaTok); in HandlePragma()
801 static void PrintPreprocessedTokens(Preprocessor &PP, Token &Tok, in PrintPreprocessedTokens() argument
804 bool DropComments = PP.getLangOpts().TraditionalCPP && in PrintPreprocessedTokens()
805 !PP.getCommentRetentionState(); in PrintPreprocessedTokens()
826 PP.Lex(Tok); in PrintPreprocessedTokens()
832 PP.Lex(Tok); in PrintPreprocessedTokens()
840 PP.Lex(Tok); in PrintPreprocessedTokens()
852 PP.Lex(Tok); in PrintPreprocessedTokens()
858 PP.Lex(Tok); in PrintPreprocessedTokens()
873 PP.Lex(Tok); in PrintPreprocessedTokens()
882 unsigned Len = PP.getSpelling(Tok, TokPtr); in PrintPreprocessedTokens()
899 std::string S = PP.getSpelling(Tok); in PrintPreprocessedTokens()
917 PP.Lex(Tok); in PrintPreprocessedTokens()
926 static void DoPrintMacros(Preprocessor &PP, raw_ostream *OS) { in DoPrintMacros() argument
928 PP.IgnorePragmas(); in DoPrintMacros()
932 PP.EnterMainSourceFile(); in DoPrintMacros()
935 do PP.Lex(Tok); in DoPrintMacros()
939 for (Preprocessor::macro_iterator I = PP.macro_begin(), E = PP.macro_end(); in DoPrintMacros()
952 PrintMacroDefinition(*MacrosByID[i].first, MI, PP, *OS); in DoPrintMacros()
959 void clang::DoPrintPreprocessedInput(Preprocessor &PP, raw_ostream *OS, in DoPrintPreprocessedInput() argument
964 DoPrintMacros(PP, OS); in DoPrintPreprocessedInput()
970 PP.SetCommentRetentionState(Opts.ShowComments, Opts.ShowMacroComments); in DoPrintPreprocessedInput()
973 PP, *OS, !Opts.ShowLineMarkers, Opts.ShowMacros, in DoPrintPreprocessedInput()
983 /*RequireTokenExpansion=*/PP.getLangOpts().MicrosoftExt)); in DoPrintPreprocessedInput()
987 /*RequireTokenExpansion=*/PP.getLangOpts().MicrosoftExt)); in DoPrintPreprocessedInput()
991 /*RequireTokenExpansion=*/PP.getLangOpts().MicrosoftExt)); in DoPrintPreprocessedInput()
993 PP.AddPragmaHandler(MicrosoftExtHandler.get()); in DoPrintPreprocessedInput()
994 PP.AddPragmaHandler("GCC", GCCHandler.get()); in DoPrintPreprocessedInput()
995 PP.AddPragmaHandler("clang", ClangHandler.get()); in DoPrintPreprocessedInput()
1005 PP.AddPragmaHandler("omp", OpenMPHandler.get()); in DoPrintPreprocessedInput()
1007 PP.addPPCallbacks(std::unique_ptr<PPCallbacks>(Callbacks)); in DoPrintPreprocessedInput()
1010 PP.EnterMainSourceFile(); in DoPrintPreprocessedInput()
1012 PP.SetMacroExpansionOnlyInDirectives(); in DoPrintPreprocessedInput()
1017 const SourceManager &SourceMgr = PP.getSourceManager(); in DoPrintPreprocessedInput()
1020 PP.Lex(Tok); in DoPrintPreprocessedInput()
1033 PrintPreprocessedTokens(PP, Tok, Callbacks, *OS); in DoPrintPreprocessedInput()
1038 PP.RemovePragmaHandler(MicrosoftExtHandler.get()); in DoPrintPreprocessedInput()
1039 PP.RemovePragmaHandler("GCC", GCCHandler.get()); in DoPrintPreprocessedInput()
1040 PP.RemovePragmaHandler("clang", ClangHandler.get()); in DoPrintPreprocessedInput()
1041 PP.RemovePragmaHandler("omp", OpenMPHandler.get()); in DoPrintPreprocessedInput()