diff options
author | Aaron Ballman <aaron@aaronballman.com> | 2015-08-28 13:20:46 +0000 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2015-08-28 13:20:46 +0000 |
commit | 56c3af312b00bd5ae646dc644a866536b13c2fb7 (patch) | |
tree | 7c014d3358c3daace02ceef53c96c05989d1e35b /clang-tidy/ClangTidy.h | |
parent | 8e50bd634a17faedf9e9018d713a75001640be9a (diff) |
Reapplying r246209, which exposed language options to the checkers. This time disable UseNullptrCheck when not compiling in C++ mode, but still allow in C++11 mode since it's likely the user wishes to modernize their code.
git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@246298 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'clang-tidy/ClangTidy.h')
-rw-r--r-- | clang-tidy/ClangTidy.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/clang-tidy/ClangTidy.h b/clang-tidy/ClangTidy.h index 2df17c2e..a2dbcbc5 100644 --- a/clang-tidy/ClangTidy.h +++ b/clang-tidy/ClangTidy.h @@ -158,6 +158,8 @@ protected: OptionsView Options; /// \brief Returns the main file name of the current translation unit. StringRef getCurrentMainFile() const { return Context->getCurrentFile(); } + /// \brief Returns the language options from the context. + LangOptions getLangOpts() const { return Context->getLangOpts(); } }; class ClangTidyCheckFactories; |