Lines Matching refs:PP
30 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
36 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
42 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
48 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
54 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
60 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
66 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
72 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
78 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
85 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
91 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
97 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
105 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
114 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
122 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
128 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
134 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
142 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
150 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
156 void HandlePragma(Preprocessor &PP, PragmaIntroducerKind Introducer,
168 PP.AddPragmaHandler(AlignHandler.get()); in initializePragmaHandlers()
171 PP.AddPragmaHandler("GCC", GCCVisibilityHandler.get()); in initializePragmaHandlers()
174 PP.AddPragmaHandler(OptionsHandler.get()); in initializePragmaHandlers()
177 PP.AddPragmaHandler(PackHandler.get()); in initializePragmaHandlers()
180 PP.AddPragmaHandler(MSStructHandler.get()); in initializePragmaHandlers()
183 PP.AddPragmaHandler(UnusedHandler.get()); in initializePragmaHandlers()
186 PP.AddPragmaHandler(WeakHandler.get()); in initializePragmaHandlers()
189 PP.AddPragmaHandler(RedefineExtnameHandler.get()); in initializePragmaHandlers()
192 PP.AddPragmaHandler("STDC", FPContractHandler.get()); in initializePragmaHandlers()
196 PP.AddPragmaHandler("OPENCL", OpenCLExtensionHandler.get()); in initializePragmaHandlers()
198 PP.AddPragmaHandler("OPENCL", FPContractHandler.get()); in initializePragmaHandlers()
204 PP.AddPragmaHandler(OpenMPHandler.get()); in initializePragmaHandlers()
208 PP.AddPragmaHandler(MSCommentHandler.get()); in initializePragmaHandlers()
213 PP.AddPragmaHandler(MSDetectMismatchHandler.get()); in initializePragmaHandlers()
215 PP.AddPragmaHandler(MSPointersToMembers.get()); in initializePragmaHandlers()
217 PP.AddPragmaHandler(MSVtorDisp.get()); in initializePragmaHandlers()
219 PP.AddPragmaHandler(MSInitSeg.get()); in initializePragmaHandlers()
221 PP.AddPragmaHandler(MSDataSeg.get()); in initializePragmaHandlers()
223 PP.AddPragmaHandler(MSBSSSeg.get()); in initializePragmaHandlers()
225 PP.AddPragmaHandler(MSConstSeg.get()); in initializePragmaHandlers()
227 PP.AddPragmaHandler(MSCodeSeg.get()); in initializePragmaHandlers()
229 PP.AddPragmaHandler(MSSection.get()); in initializePragmaHandlers()
231 PP.AddPragmaHandler(MSRuntimeChecks.get()); in initializePragmaHandlers()
235 PP.AddPragmaHandler("clang", OptimizeHandler.get()); in initializePragmaHandlers()
238 PP.AddPragmaHandler("clang", LoopHintHandler.get()); in initializePragmaHandlers()
241 PP.AddPragmaHandler(UnrollHintHandler.get()); in initializePragmaHandlers()
244 PP.AddPragmaHandler(NoUnrollHintHandler.get()); in initializePragmaHandlers()
249 PP.RemovePragmaHandler(AlignHandler.get()); in resetPragmaHandlers()
251 PP.RemovePragmaHandler("GCC", GCCVisibilityHandler.get()); in resetPragmaHandlers()
253 PP.RemovePragmaHandler(OptionsHandler.get()); in resetPragmaHandlers()
255 PP.RemovePragmaHandler(PackHandler.get()); in resetPragmaHandlers()
257 PP.RemovePragmaHandler(MSStructHandler.get()); in resetPragmaHandlers()
259 PP.RemovePragmaHandler(UnusedHandler.get()); in resetPragmaHandlers()
261 PP.RemovePragmaHandler(WeakHandler.get()); in resetPragmaHandlers()
263 PP.RemovePragmaHandler(RedefineExtnameHandler.get()); in resetPragmaHandlers()
267 PP.RemovePragmaHandler("OPENCL", OpenCLExtensionHandler.get()); in resetPragmaHandlers()
269 PP.RemovePragmaHandler("OPENCL", FPContractHandler.get()); in resetPragmaHandlers()
271 PP.RemovePragmaHandler(OpenMPHandler.get()); in resetPragmaHandlers()
275 PP.RemovePragmaHandler(MSCommentHandler.get()); in resetPragmaHandlers()
280 PP.RemovePragmaHandler(MSDetectMismatchHandler.get()); in resetPragmaHandlers()
282 PP.RemovePragmaHandler(MSPointersToMembers.get()); in resetPragmaHandlers()
284 PP.RemovePragmaHandler(MSVtorDisp.get()); in resetPragmaHandlers()
286 PP.RemovePragmaHandler(MSInitSeg.get()); in resetPragmaHandlers()
288 PP.RemovePragmaHandler(MSDataSeg.get()); in resetPragmaHandlers()
290 PP.RemovePragmaHandler(MSBSSSeg.get()); in resetPragmaHandlers()
292 PP.RemovePragmaHandler(MSConstSeg.get()); in resetPragmaHandlers()
294 PP.RemovePragmaHandler(MSCodeSeg.get()); in resetPragmaHandlers()
296 PP.RemovePragmaHandler(MSSection.get()); in resetPragmaHandlers()
298 PP.RemovePragmaHandler(MSRuntimeChecks.get()); in resetPragmaHandlers()
302 PP.RemovePragmaHandler("STDC", FPContractHandler.get()); in resetPragmaHandlers()
305 PP.RemovePragmaHandler("clang", OptimizeHandler.get()); in resetPragmaHandlers()
308 PP.RemovePragmaHandler("clang", LoopHintHandler.get()); in resetPragmaHandlers()
311 PP.RemovePragmaHandler(UnrollHintHandler.get()); in resetPragmaHandlers()
314 PP.RemovePragmaHandler(NoUnrollHintHandler.get()); in resetPragmaHandlers()
436 PP.Diag(Tok, diag::err_expected) << tok::l_brace; in HandlePragmaCaptured()
486 PP.Diag(NameLoc, diag::warn_pragma_extension_is_core) << ename; \ in HandlePragmaOpenCLExtension()
488 PP.Diag(NameLoc, diag::warn_pragma_unsupported_extension) << ename; in HandlePragmaOpenCLExtension()
491 PP.Diag(NameLoc, diag::warn_pragma_unknown_extension) << ename; in HandlePragmaOpenCLExtension()
520 PP.EnterTokenStream(std::move(TheTokens->first), TheTokens->second, true); in HandlePragmaMSPragma()
524 PP.Lex(Tok); // pragma kind in HandlePragmaMSPragma()
541 PP.Lex(Tok); in HandlePragmaMSPragma()
542 PP.Lex(Tok); in HandlePragmaMSPragma()
549 PP.Diag(PragmaLocation, diag::warn_pragma_expected_lparen) << PragmaName; in HandlePragmaMSSection()
552 PP.Lex(Tok); // ( in HandlePragmaMSSection()
555 PP.Diag(PragmaLocation, diag::warn_pragma_expected_section_name) in HandlePragmaMSSection()
564 PP.Diag(PragmaLocation, diag::warn_pragma_expected_non_wide_string) in HandlePragmaMSSection()
571 PP.Lex(Tok); // , in HandlePragmaMSSection()
576 PP.Lex(Tok); // long/short in HandlePragmaMSSection()
581 PP.Diag(PragmaLocation, diag::warn_pragma_expected_action_or_r_paren) in HandlePragmaMSSection()
598 PP.Diag(PragmaLocation, Flag == ASTContext::PSF_None in HandlePragmaMSSection()
606 PP.Lex(Tok); // Identifier in HandlePragmaMSSection()
613 PP.Diag(PragmaLocation, diag::warn_pragma_expected_rparen) << PragmaName; in HandlePragmaMSSection()
616 PP.Lex(Tok); // ) in HandlePragmaMSSection()
618 PP.Diag(PragmaLocation, diag::warn_pragma_extra_tokens_at_eol) in HandlePragmaMSSection()
622 PP.Lex(Tok); // eof in HandlePragmaMSSection()
630 PP.Diag(PragmaLocation, diag::warn_pragma_expected_lparen) << PragmaName; in HandlePragmaMSSegment()
633 PP.Lex(Tok); // ( in HandlePragmaMSSegment()
643 PP.Diag(PragmaLocation, in HandlePragmaMSSegment()
649 PP.Lex(Tok); // push | pop in HandlePragmaMSSegment()
651 PP.Lex(Tok); // , in HandlePragmaMSSegment()
655 PP.Lex(Tok); // identifier in HandlePragmaMSSegment()
657 PP.Lex(Tok); in HandlePragmaMSSegment()
659 PP.Diag(PragmaLocation, diag::warn_pragma_expected_punc) in HandlePragmaMSSegment()
665 PP.Diag(PragmaLocation, diag::warn_pragma_expected_punc) << PragmaName; in HandlePragmaMSSegment()
678 PP.Diag(PragmaLocation, DiagID) << PragmaName; in HandlePragmaMSSegment()
686 PP.Diag(PragmaLocation, diag::warn_pragma_expected_non_wide_string) in HandlePragmaMSSegment()
695 PP.Diag(PragmaLocation, diag::warn_pragma_expected_rparen) << PragmaName; in HandlePragmaMSSegment()
698 PP.Lex(Tok); // ) in HandlePragmaMSSegment()
700 PP.Diag(PragmaLocation, diag::warn_pragma_extra_tokens_at_eol) in HandlePragmaMSSegment()
704 PP.Lex(Tok); // eof in HandlePragmaMSSegment()
714 PP.Diag(PragmaLocation, diag::warn_pragma_init_seg_unsupported_target); in HandlePragmaMSInitSeg()
742 PP.Lex(Tok); in HandlePragmaMSInitSeg()
750 PP.Diag(PragmaLocation, diag::warn_pragma_expected_non_wide_string) in HandlePragmaMSInitSeg()
758 PP.Diag(PragmaLocation, diag::warn_pragma_expected_init_seg) << PragmaName; in HandlePragmaMSInitSeg()
875 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/false); in HandlePragmaLoopHint()
907 void PragmaGCCVisibilityHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
913 PP.LexUnexpandedToken(Tok); in HandlePragma()
921 PP.LexUnexpandedToken(Tok); in HandlePragma()
923 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_lparen) in HandlePragma()
927 PP.LexUnexpandedToken(Tok); in HandlePragma()
930 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) in HandlePragma()
934 PP.LexUnexpandedToken(Tok); in HandlePragma()
936 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_rparen) in HandlePragma()
941 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) in HandlePragma()
946 PP.LexUnexpandedToken(Tok); in HandlePragma()
948 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
960 PP.EnterTokenStream(std::move(Toks), 1, /*DisableMacroExpansion=*/true); in HandlePragma()
967 void PragmaPackHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
973 PP.Lex(Tok); in HandlePragma()
975 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_lparen) << "pack"; in HandlePragma()
983 PP.Lex(Tok); in HandlePragma()
987 PP.Lex(Tok); in HandlePragma()
993 PP.getLangOpts().ApplePragmaPack ? Sema::PSK_Push_Set : Sema::PSK_Set; in HandlePragma()
998 PP.Lex(Tok); in HandlePragma()
1005 PP.Diag(Tok.getLocation(), diag::warn_pragma_invalid_action) << "pack"; in HandlePragma()
1008 PP.Lex(Tok); in HandlePragma()
1011 PP.Lex(Tok); in HandlePragma()
1017 PP.Lex(Tok); in HandlePragma()
1020 PP.Lex(Tok); in HandlePragma()
1023 PP.Lex(Tok); in HandlePragma()
1026 PP.Diag(Tok.getLocation(), diag::warn_pragma_pack_malformed); in HandlePragma()
1033 PP.Lex(Tok); in HandlePragma()
1036 PP.Diag(Tok.getLocation(), diag::warn_pragma_pack_malformed); in HandlePragma()
1041 } else if (PP.getLangOpts().ApplePragmaPack) { in HandlePragma()
1049 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_rparen) << "pack"; in HandlePragma()
1054 PP.Lex(Tok); in HandlePragma()
1056 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) << "pack"; in HandlePragma()
1061 PP.getPreprocessorAllocator().Allocate<PragmaPackInfo>(1); in HandlePragma()
1066 MutableArrayRef<Token> Toks(PP.getPreprocessorAllocator().Allocate<Token>(1), in HandlePragma()
1073 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1078 void PragmaMSStructHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1084 PP.Lex(Tok); in HandlePragma()
1086 PP.Diag(Tok.getLocation(), diag::warn_pragma_ms_struct); in HandlePragma()
1093 PP.Lex(Tok); in HandlePragma()
1096 PP.Lex(Tok); in HandlePragma()
1098 PP.Diag(Tok.getLocation(), diag::warn_pragma_ms_struct); in HandlePragma()
1103 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
1108 MutableArrayRef<Token> Toks(PP.getPreprocessorAllocator().Allocate<Token>(1), in HandlePragma()
1116 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1121 static void ParseAlignPragma(Preprocessor &PP, Token &FirstTok, in ParseAlignPragma() argument
1126 PP.Lex(Tok); in ParseAlignPragma()
1129 PP.Diag(Tok.getLocation(), diag::warn_pragma_options_expected_align); in ParseAlignPragma()
1134 PP.Lex(Tok); in ParseAlignPragma()
1136 PP.Diag(Tok.getLocation(), diag::warn_pragma_align_expected_equal) in ParseAlignPragma()
1141 PP.Lex(Tok); in ParseAlignPragma()
1143 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) in ParseAlignPragma()
1163 PP.Diag(Tok.getLocation(), diag::warn_pragma_align_invalid_option) in ParseAlignPragma()
1169 PP.Lex(Tok); in ParseAlignPragma()
1171 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in ParseAlignPragma()
1176 MutableArrayRef<Token> Toks(PP.getPreprocessorAllocator().Allocate<Token>(1), in ParseAlignPragma()
1184 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in ParseAlignPragma()
1187 void PragmaAlignHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1190 ParseAlignPragma(PP, AlignTok, /*IsOptions=*/false); in HandlePragma()
1193 void PragmaOptionsHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1196 ParseAlignPragma(PP, OptionsTok, /*IsOptions=*/true); in HandlePragma()
1200 void PragmaUnusedHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1208 PP.Lex(Tok); in HandlePragma()
1210 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_lparen) << "unused"; in HandlePragma()
1220 PP.Lex(Tok); in HandlePragma()
1230 PP.Diag(Tok.getLocation(), diag::warn_pragma_unused_expected_var); in HandlePragma()
1246 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_punc) << "unused"; in HandlePragma()
1250 PP.Lex(Tok); in HandlePragma()
1252 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) << in HandlePragma()
1267 PP.getPreprocessorAllocator().Allocate<Token>(2 * Identifiers.size()), in HandlePragma()
1276 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1281 void PragmaWeakHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1287 PP.Lex(Tok); in HandlePragma()
1289 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) << "weak"; in HandlePragma()
1297 PP.Lex(Tok); in HandlePragma()
1300 PP.Lex(Tok); in HandlePragma()
1302 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) in HandlePragma()
1307 PP.Lex(Tok); in HandlePragma()
1311 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) << "weak"; in HandlePragma()
1317 PP.getPreprocessorAllocator().Allocate<Token>(3), 3); in HandlePragma()
1325 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1328 PP.getPreprocessorAllocator().Allocate<Token>(2), 2); in HandlePragma()
1335 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1340 void PragmaRedefineExtnameHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1346 PP.Lex(Tok); in HandlePragma()
1348 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) << in HandlePragma()
1354 PP.Lex(Tok); in HandlePragma()
1357 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) in HandlePragma()
1363 PP.Lex(Tok); in HandlePragma()
1366 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) << in HandlePragma()
1371 MutableArrayRef<Token> Toks(PP.getPreprocessorAllocator().Allocate<Token>(3), in HandlePragma()
1380 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1385 PragmaFPContractHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1389 if (PP.LexOnOffSwitch(OOS)) in HandlePragma()
1392 MutableArrayRef<Token> Toks(PP.getPreprocessorAllocator().Allocate<Token>(1), in HandlePragma()
1400 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1404 PragmaOpenCLExtensionHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1407 PP.LexUnexpandedToken(Tok); in HandlePragma()
1409 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) << in HandlePragma()
1416 PP.Lex(Tok); in HandlePragma()
1418 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_colon) << ename; in HandlePragma()
1422 PP.Lex(Tok); in HandlePragma()
1424 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_enable_disable); in HandlePragma()
1435 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_enable_disable); in HandlePragma()
1440 PP.Lex(Tok); in HandlePragma()
1442 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) << in HandlePragma()
1448 MutableArrayRef<Token> Toks(PP.getPreprocessorAllocator().Allocate<Token>(1), in HandlePragma()
1455 PP.EnterTokenStream(Toks, /*DisableMacroExpansion=*/true); in HandlePragma()
1457 if (PP.getPPCallbacks()) in HandlePragma()
1458 PP.getPPCallbacks()->PragmaOpenCLExtension(NameLoc, ename, in HandlePragma()
1465 PragmaNoOpenMPHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1468 if (!PP.getDiagnostics().isIgnored(diag::warn_pragma_omp_ignored, in HandlePragma()
1470 PP.Diag(FirstTok, diag::warn_pragma_omp_ignored); in HandlePragma()
1471 PP.getDiagnostics().setSeverity(diag::warn_pragma_omp_ignored, in HandlePragma()
1474 PP.DiscardUntilEndOfDirective(); in HandlePragma()
1480 PragmaOpenMPHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1491 PP.Lex(Tok); in HandlePragma()
1501 PP.EnterTokenStream(std::move(Toks), Pragma.size(), in HandlePragma()
1513 void PragmaMSPointersToMembers::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1517 PP.Lex(Tok); in HandlePragma()
1519 PP.Diag(PointersToMembersLoc, diag::warn_pragma_expected_lparen) in HandlePragma()
1523 PP.Lex(Tok); in HandlePragma()
1526 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_identifier) in HandlePragma()
1530 PP.Lex(Tok); in HandlePragma()
1538 PP.Lex(Tok); in HandlePragma()
1542 PP.Diag(Tok.getLocation(), in HandlePragma()
1547 PP.Lex(Tok); in HandlePragma()
1554 PP.Diag(Tok.getLocation(), diag::err_expected_punc) in HandlePragma()
1571 PP.Diag(Tok.getLocation(), in HandlePragma()
1580 PP.Diag(Tok.getLocation(), diag::err_expected_rparen_after) in HandlePragma()
1586 PP.Lex(Tok); in HandlePragma()
1588 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
1600 PP.EnterToken(AnnotTok); in HandlePragma()
1611 void PragmaMSVtorDisp::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1615 PP.Lex(Tok); in HandlePragma()
1617 PP.Diag(VtorDispLoc, diag::warn_pragma_expected_lparen) << "vtordisp"; in HandlePragma()
1620 PP.Lex(Tok); in HandlePragma()
1627 PP.Lex(Tok); in HandlePragma()
1629 PP.Diag(VtorDispLoc, diag::warn_pragma_expected_punc) << "vtordisp"; in HandlePragma()
1632 PP.Lex(Tok); in HandlePragma()
1637 PP.Lex(Tok); in HandlePragma()
1653 PP.Lex(Tok); in HandlePragma()
1656 PP.Lex(Tok); in HandlePragma()
1659 PP.parseSimpleIntegerLiteral(Tok, Value)) { in HandlePragma()
1661 PP.Diag(Tok.getLocation(), diag::warn_pragma_expected_integer) in HandlePragma()
1666 PP.Diag(Tok.getLocation(), diag::warn_pragma_invalid_action) in HandlePragma()
1674 PP.Diag(VtorDispLoc, diag::warn_pragma_expected_rparen) << "vtordisp"; in HandlePragma()
1678 PP.Lex(Tok); in HandlePragma()
1680 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
1693 PP.EnterToken(AnnotTok); in HandlePragma()
1698 void PragmaMSPragma::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1710 for (; Tok.isNot(tok::eod); PP.Lex(Tok)) { in HandlePragma()
1720 auto Value = new (PP.getPreprocessorAllocator()) in HandlePragma()
1724 PP.EnterToken(AnnotTok); in HandlePragma()
1737 void PragmaDetectMismatchHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1741 PP.Lex(Tok); in HandlePragma()
1743 PP.Diag(DetectMismatchLoc, diag::err_expected) << tok::l_paren; in HandlePragma()
1749 if (!PP.LexStringLiteral(Tok, NameString, in HandlePragma()
1757 PP.Diag(Tok.getLocation(), diag::err_pragma_detect_mismatch_malformed); in HandlePragma()
1761 if (!PP.LexStringLiteral(Tok, ValueString, "pragma detect_mismatch", in HandlePragma()
1766 PP.Diag(Tok.getLocation(), diag::err_expected) << tok::r_paren; in HandlePragma()
1769 PP.Lex(Tok); // Eat the r_paren. in HandlePragma()
1772 PP.Diag(Tok.getLocation(), diag::err_pragma_detect_mismatch_malformed); in HandlePragma()
1777 if (PP.getPPCallbacks()) in HandlePragma()
1778 PP.getPPCallbacks()->PragmaDetectMismatch(DetectMismatchLoc, NameString, in HandlePragma()
1793 void PragmaCommentHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1797 PP.Lex(Tok); in HandlePragma()
1799 PP.Diag(CommentLoc, diag::err_pragma_comment_malformed); in HandlePragma()
1804 PP.Lex(Tok); in HandlePragma()
1806 PP.Diag(CommentLoc, diag::err_pragma_comment_malformed); in HandlePragma()
1821 PP.Diag(Tok.getLocation(), diag::err_pragma_comment_unknown_kind); in HandlePragma()
1827 if (PP.getTargetInfo().getTriple().isPS4() && Kind != PCK_Lib) { in HandlePragma()
1828 PP.Diag(Tok.getLocation(), diag::warn_pragma_comment_ignored) in HandlePragma()
1834 PP.Lex(Tok); in HandlePragma()
1836 if (Tok.is(tok::comma) && !PP.LexStringLiteral(Tok, ArgumentString, in HandlePragma()
1849 PP.Diag(Tok.getLocation(), diag::err_pragma_comment_malformed); in HandlePragma()
1852 PP.Lex(Tok); // eat the r_paren. in HandlePragma()
1855 PP.Diag(Tok.getLocation(), diag::err_pragma_comment_malformed); in HandlePragma()
1860 if (PP.getPPCallbacks()) in HandlePragma()
1861 PP.getPPCallbacks()->PragmaComment(CommentLoc, II, ArgumentString); in HandlePragma()
1868 void PragmaOptimizeHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1872 PP.Lex(Tok); in HandlePragma()
1874 PP.Diag(Tok.getLocation(), diag::err_pragma_missing_argument) in HandlePragma()
1879 PP.Diag(Tok.getLocation(), diag::err_pragma_optimize_invalid_argument) in HandlePragma()
1880 << PP.getSpelling(Tok); in HandlePragma()
1889 PP.Diag(Tok.getLocation(), diag::err_pragma_optimize_invalid_argument) in HandlePragma()
1890 << PP.getSpelling(Tok); in HandlePragma()
1893 PP.Lex(Tok); in HandlePragma()
1896 PP.Diag(Tok.getLocation(), diag::err_pragma_optimize_extra_argument) in HandlePragma()
1897 << PP.getSpelling(Tok); in HandlePragma()
1905 static bool ParseLoopHintValue(Preprocessor &PP, Token &Tok, Token PragmaName, in ParseLoopHintValue() argument
1921 PP.Lex(Tok); in ParseLoopHintValue()
1927 PP.Diag(Tok.getLocation(), diag::err_expected) << tok::r_paren; in ParseLoopHintValue()
1930 PP.Lex(Tok); in ParseLoopHintValue()
1939 Info.Toks = llvm::makeArrayRef(ValueList).copy(PP.getPreprocessorAllocator()); in ParseLoopHintValue()
1991 void PragmaLoopHintHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
1999 PP.Lex(Tok); in HandlePragma()
2001 PP.Diag(Tok.getLocation(), diag::err_pragma_loop_invalid_option) in HandlePragma()
2020 PP.Diag(Tok.getLocation(), diag::err_pragma_loop_invalid_option) in HandlePragma()
2024 PP.Lex(Tok); in HandlePragma()
2028 PP.Diag(Tok.getLocation(), diag::err_expected) << tok::l_paren; in HandlePragma()
2031 PP.Lex(Tok); in HandlePragma()
2033 auto *Info = new (PP.getPreprocessorAllocator()) PragmaLoopHintInfo; in HandlePragma()
2034 if (ParseLoopHintValue(PP, Tok, PragmaName, Option, /*ValueInParens=*/true, in HandlePragma()
2049 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
2057 PP.EnterTokenStream(std::move(TokenArray), TokenList.size(), in HandlePragma()
2078 void PragmaUnrollHintHandler::HandlePragma(Preprocessor &PP, in HandlePragma() argument
2084 PP.Lex(Tok); in HandlePragma()
2085 auto *Info = new (PP.getPreprocessorAllocator()) PragmaLoopHintInfo; in HandlePragma()
2091 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
2100 PP.Lex(Tok); in HandlePragma()
2104 if (ParseLoopHintValue(PP, Tok, PragmaName, Option, ValueInParens, *Info)) in HandlePragma()
2109 if (PP.getLangOpts().CUDA && ValueInParens) in HandlePragma()
2110 PP.Diag(Info->Toks[0].getLocation(), in HandlePragma()
2114 PP.Diag(Tok.getLocation(), diag::warn_pragma_extra_tokens_at_eol) in HandlePragma()
2127 PP.EnterTokenStream(std::move(TokenArray), 1, in HandlePragma()