@@ -301,13 +301,9 @@ struct PragmaMSRuntimeChecksHandler : public EmptyPragmaHandler {
301301};
302302
303303struct PragmaMSIntrinsicHandler : public PragmaHandler {
304- PragmaMSIntrinsicHandler (Sema &Actions)
305- : PragmaHandler(" intrinsic" ), Actions(Actions) {}
304+ PragmaMSIntrinsicHandler () : PragmaHandler(" intrinsic" ) {}
306305 void HandlePragma (Preprocessor &PP, PragmaIntroducer Introducer,
307306 Token &FirstToken) override ;
308-
309- private:
310- Sema &Actions;
311307};
312308
313309// "\#pragma fenv_access (on)".
@@ -521,7 +517,7 @@ void Parser::initializePragmaHandlers() {
521517 PP.AddPragmaHandler (MSOptimize.get ());
522518 MSRuntimeChecks = std::make_unique<PragmaMSRuntimeChecksHandler>();
523519 PP.AddPragmaHandler (MSRuntimeChecks.get ());
524- MSIntrinsic = std::make_unique<PragmaMSIntrinsicHandler>(Actions );
520+ MSIntrinsic = std::make_unique<PragmaMSIntrinsicHandler>();
525521 PP.AddPragmaHandler (MSIntrinsic.get ());
526522 MSFenvAccess = std::make_unique<PragmaMSFenvAccessHandler>();
527523 PP.AddPragmaHandler (MSFenvAccess.get ());
@@ -3797,15 +3793,7 @@ void PragmaMSIntrinsicHandler::HandlePragma(Preprocessor &PP,
37973793 if (!II->getBuiltinID ())
37983794 PP.Diag (Tok.getLocation (), diag::warn_pragma_intrinsic_builtin)
37993795 << II << SuggestIntrinH;
3800- // If the builtin hasn't already been declared, declare it now.
3801- DeclarationNameInfo NameInfo (II, Tok.getLocation ());
3802- LookupResult Previous (Actions, NameInfo, Sema::LookupOrdinaryName,
3803- Actions.forRedeclarationInCurContext ());
3804- Actions.LookupName (Previous, Actions.getCurScope (),
3805- /* CreateBuiltins*/ false );
3806- if (Previous.empty ())
3807- Actions.LazilyCreateBuiltin (II, II->getBuiltinID (), Actions.getCurScope (),
3808- /* ForRedeclaration*/ true , Tok.getLocation ());
3796+
38093797 PP.Lex (Tok);
38103798 if (Tok.isNot (tok::comma))
38113799 break ;
0 commit comments