1 diff --git a/clang-tools-extra/clang-tidy/ClangTidy.cpp b/clang-tools-extra/clang-tidy/ClangTidy.cpp
2 index 7de313ad4da6..697f98c362d1 100644
3 --- a/clang-tools-extra/clang-tidy/ClangTidy.cpp
4 +++ b/clang-tools-extra/clang-tidy/ClangTidy.cpp
5 @@ -432,6 +432,7 @@ ClangTidyASTConsumerFactory::createASTConsumer(
7 for (auto &Check : Checks) {
8 Check->registerMatchers(&*Finder);
9 + Check->registerPPCallbacks(Compiler);
10 Check->registerPPCallbacks(*SM, PP, ModuleExpanderPP);
13 diff --git a/clang-tools-extra/clang-tidy/ClangTidyCheck.h b/clang-tools-extra/clang-tidy/ClangTidyCheck.h
14 index 9b41e5836de7..d8938b8fe05e 100644
15 --- a/clang-tools-extra/clang-tidy/ClangTidyCheck.h
16 +++ b/clang-tools-extra/clang-tidy/ClangTidyCheck.h
21 +class CompilerInstance;
25 @@ -69,6 +70,9 @@ public:
29 + /// This has been deprecated in clang 9 - needed by mozilla-must-override
30 + virtual void registerPPCallbacks(CompilerInstance &Compiler) {}
32 /// Override this to register ``PPCallbacks`` in the preprocessor.
34 /// This should be used for clang-tidy checks that analyze preprocessor-