Lines Matching refs:PP
36 Preprocessor &PP, raw_ostream &OS) { in PrintMacroDefinition() argument
71 OS << PP.getSpelling(T, SpellingBuffer); in PrintMacroDefinition()
81 Preprocessor &PP; member in __anon48d32a1d0111::PrintPPOutputPPCallbacks
101 : PP(pp), SM(PP.getSourceManager()), ConcatInfo(PP), OS(os), in PrintPPOutputPPCallbacks()
329 if (PP.getLangOpts().ObjC2) { in InclusionDirective()
370 PrintMacroDefinition(*MacroNameTok.getIdentifierInfo(), *MI, PP, OS); in MacroDefined()
584 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer, in HandlePragma()
597 PP.EnterTokenStream(std::move(Toks), /*NumToks=*/1, in HandlePragma()
599 PP.Lex(PragmaTok); in HandlePragma()
611 std::string TokSpell = PP.getSpelling(PragmaTok); in HandlePragma()
618 PP.Lex(PragmaTok); in HandlePragma()
620 PP.LexUnexpandedToken(PragmaTok); in HandlePragma()
628 static void PrintPreprocessedTokens(Preprocessor &PP, Token &Tok, in PrintPreprocessedTokens() argument
631 bool DropComments = PP.getLangOpts().TraditionalCPP && in PrintPreprocessedTokens()
632 !PP.getCommentRetentionState(); in PrintPreprocessedTokens()
667 PP.Lex(Tok); in PrintPreprocessedTokens()
676 unsigned Len = PP.getSpelling(Tok, TokPtr); in PrintPreprocessedTokens()
684 std::string S = PP.getSpelling(Tok); in PrintPreprocessedTokens()
698 PP.Lex(Tok); in PrintPreprocessedTokens()
707 static void DoPrintMacros(Preprocessor &PP, raw_ostream *OS) { in DoPrintMacros() argument
709 PP.IgnorePragmas(); in DoPrintMacros()
713 PP.EnterMainSourceFile(); in DoPrintMacros()
716 do PP.Lex(Tok); in DoPrintMacros()
720 for (Preprocessor::macro_iterator I = PP.macro_begin(), E = PP.macro_end(); in DoPrintMacros()
733 PrintMacroDefinition(*MacrosByID[i].first, MI, PP, *OS); in DoPrintMacros()
740 void clang::DoPrintPreprocessedInput(Preprocessor &PP, raw_ostream *OS, in DoPrintPreprocessedInput() argument
745 DoPrintMacros(PP, OS); in DoPrintPreprocessedInput()
751 PP.SetCommentRetentionState(Opts.ShowComments, Opts.ShowMacroComments); in DoPrintPreprocessedInput()
754 PP, *OS, !Opts.ShowLineMarkers, Opts.ShowMacros, Opts.UseLineDirectives); in DoPrintPreprocessedInput()
758 PP.AddPragmaHandler(new UnknownPragmaHandler( in DoPrintPreprocessedInput()
760 /*RequireTokenExpansion=*/PP.getLangOpts().MicrosoftExt)); in DoPrintPreprocessedInput()
761 PP.AddPragmaHandler( in DoPrintPreprocessedInput()
764 /*RequireTokenExpansion=*/PP.getLangOpts().MicrosoftExt)); in DoPrintPreprocessedInput()
765 PP.AddPragmaHandler( in DoPrintPreprocessedInput()
768 /*RequireTokenExpansion=*/PP.getLangOpts().MicrosoftExt)); in DoPrintPreprocessedInput()
775 PP.AddPragmaHandler("omp", in DoPrintPreprocessedInput()
779 PP.addPPCallbacks(std::unique_ptr<PPCallbacks>(Callbacks)); in DoPrintPreprocessedInput()
782 PP.EnterMainSourceFile(); in DoPrintPreprocessedInput()
787 const SourceManager &SourceMgr = PP.getSourceManager(); in DoPrintPreprocessedInput()
790 PP.Lex(Tok); in DoPrintPreprocessedInput()
803 PrintPreprocessedTokens(PP, Tok, Callbacks, *OS); in DoPrintPreprocessedInput()