diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2009-06-05 07:05:05 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2009-06-05 07:05:05 +0000 |
commit | 15b91764d08e886391c865c4a444d7b51141c284 (patch) | |
tree | 9b8fc62dbdf966c02173489549e71d6928cb81e3 /include/clang/Basic | |
parent | 145c6090752187228340edc9a2bec8f6b74841cf (diff) |
Move CharIsSigned from TargetInfo to LangOptions.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@72928 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic')
-rw-r--r-- | include/clang/Basic/DiagnosticFrontendKinds.td | 3 | ||||
-rw-r--r-- | include/clang/Basic/LangOptions.h | 3 | ||||
-rw-r--r-- | include/clang/Basic/TargetInfo.h | 6 |
3 files changed, 6 insertions, 6 deletions
diff --git a/include/clang/Basic/DiagnosticFrontendKinds.td b/include/clang/Basic/DiagnosticFrontendKinds.td index 1bc296babd..ae5246d792 100644 --- a/include/clang/Basic/DiagnosticFrontendKinds.td +++ b/include/clang/Basic/DiagnosticFrontendKinds.td @@ -130,6 +130,9 @@ def warn_pch_compiler_options_mismatch : Error< def warn_pch_access_control : Error< "C++ access control was %select{disabled|enabled}0 in the PCH file but " "is currently %select{disabled|enabled}1">; +def warn_pch_char_signed : Error< + "char was %select{unsigned|signed}0 in the PCH file but " + "is currently %select{unsigned|signed}1">; def err_not_a_pch_file : Error< "'%0' does not appear to be a precompiled header file">, DefaultFatal; diff --git a/include/clang/Basic/LangOptions.h b/include/clang/Basic/LangOptions.h index 92370cdd9e..7c578e32f8 100644 --- a/include/clang/Basic/LangOptions.h +++ b/include/clang/Basic/LangOptions.h @@ -79,6 +79,7 @@ public: unsigned AccessControl : 1; // Whether C++ access control should // be enabled. + unsigned CharIsSigned : 1; // Whether char is a signed or unsigned type private: unsigned GC : 2; // Objective-C Garbage Collection modes. We declare // this enum as unsigned because MSVC insists on making enums @@ -137,6 +138,8 @@ public: GNUInline = 0; NoInline = 0; + CharIsSigned = 1; + MainFileName = 0; } diff --git a/include/clang/Basic/TargetInfo.h b/include/clang/Basic/TargetInfo.h index f577d6b322..a59c60b002 100644 --- a/include/clang/Basic/TargetInfo.h +++ b/include/clang/Basic/TargetInfo.h @@ -38,7 +38,6 @@ class TargetInfo { protected: // Target values set by the ctor of the actual target implementation. Default // values are specified by the TargetInfo constructor. - bool CharIsSigned; bool TLSSupported; unsigned char PointerWidth, PointerAlign; unsigned char WCharWidth, WCharAlign; @@ -88,11 +87,6 @@ public: IntType getIntPtrType() const { return IntPtrType; } IntType getWCharType() const { return WCharType; } - /// isCharSigned - Return true if 'char' is 'signed char' or false if it is - /// treated as 'unsigned char'. This is implementation defined according to - /// C99 6.2.5p15. In our implementation, this is target-specific. - bool isCharSigned() const { return CharIsSigned; } - /// getPointerWidth - Return the width of pointers on this target, for the /// specified address space. uint64_t getPointerWidth(unsigned AddrSpace) const { |