CHAR_BIT == 8
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64286 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/AST/Type.cpp b/lib/AST/Type.cpp
index ac8e4f1..d844d6c 100644
--- a/lib/AST/Type.cpp
+++ b/lib/AST/Type.cpp
@@ -894,7 +894,7 @@
void
ClassTemplateSpecializationType::
packBooleanValues(unsigned NumArgs, bool *Values, uintptr_t *Words) {
- const unsigned BitsPerWord = sizeof(uintptr_t) * CHAR_BIT;
+ const unsigned BitsPerWord = sizeof(uintptr_t) * 8;
for (unsigned PW = 0, NumPackedWords = getNumPackedWords(NumArgs), Arg = 0;
PW != NumPackedWords; ++PW) {
@@ -940,7 +940,7 @@
}
bool ClassTemplateSpecializationType::isArgType(unsigned Arg) const {
- const unsigned BitsPerWord = sizeof(uintptr_t) * CHAR_BIT;
+ const unsigned BitsPerWord = sizeof(uintptr_t) * 8;
const uintptr_t *Data = reinterpret_cast<const uintptr_t *>(this + 1);
Data += Arg / BitsPerWord;
return (*Data >> ((NumArgs - Arg) % BitsPerWord - 1)) & 0x01;