diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2011-08-30 23:07:51 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2011-08-30 23:07:51 +0000 |
commit | f84139a1331c63c998e8b7d54148c75ac0b48ccd (patch) | |
tree | f5e89a672f189361fb2ebcabfee83e3256f9a6c2 /include/clang/Lex/Preprocessor.h | |
parent | 1155c42e7b1b4e401bb0a331a6d715d637958c75 (diff) |
Change err_pp_file_not_found back to an Error; when it's a Warning, we suppress it in system headers. And it is not a good idea to suppress it in system headers. (This was originally changed in r134996 to implement -MG.)
Fixes <rdar://10041960>. And also brings down the number of warnings without a flag by one :)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138842 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Lex/Preprocessor.h')
-rw-r--r-- | include/clang/Lex/Preprocessor.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/clang/Lex/Preprocessor.h b/include/clang/Lex/Preprocessor.h index b14c7e8382..c3557a5e93 100644 --- a/include/clang/Lex/Preprocessor.h +++ b/include/clang/Lex/Preprocessor.h @@ -105,6 +105,7 @@ class Preprocessor : public llvm::RefCountedBase<Preprocessor> { // State that is set before the preprocessor begins. bool KeepComments : 1; bool KeepMacroComments : 1; + bool SuppressIncludeNotFoundError : 1; // State that changes while the preprocessor runs: bool InMacroArgs : 1; // True if parsing fn macro invocation args. @@ -344,6 +345,14 @@ public: bool getCommentRetentionState() const { return KeepComments; } + void SetSuppressIncludeNotFoundError(bool Suppress) { + SuppressIncludeNotFoundError = Suppress; + } + + bool GetSuppressIncludeNotFoundError() { + return SuppressIncludeNotFoundError; + } + /// isCurrentLexer - Return true if we are lexing directly from the specified /// lexer. bool isCurrentLexer(const PreprocessorLexer *L) const { |