Made the mechanism of defining preprocessor defs for maxint, ptrdiff_t, wchar
etc more generic. For some targets, long may not be equal to pointer size. For
example: PIC16 has int as i16, ptr as i16 but long as i32.
Also fixed a few build warnings in assert() functions in CFRefCount.cpp,
CGDecl.cpp, SemaDeclCXX.cpp and ParseDeclCXX.cpp.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@58501 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Parse/ParseDeclCXX.cpp b/lib/Parse/ParseDeclCXX.cpp
index 21c7d6f..7d03c59 100644
--- a/lib/Parse/ParseDeclCXX.cpp
+++ b/lib/Parse/ParseDeclCXX.cpp
@@ -551,9 +551,9 @@
///
void Parser::ParseCXXMemberSpecification(SourceLocation RecordLoc,
unsigned TagType, DeclTy *TagDecl) {
- assert(TagType == DeclSpec::TST_struct ||
+ assert((TagType == DeclSpec::TST_struct ||
TagType == DeclSpec::TST_union ||
- TagType == DeclSpec::TST_class && "Invalid TagType!");
+ TagType == DeclSpec::TST_class) && "Invalid TagType!");
SourceLocation LBraceLoc = ConsumeBrace();
@@ -626,8 +626,8 @@
// For a local class of inline method, pop the LexedMethodsForTopClass that
// was previously pushed.
- assert(CurScope->isInCXXInlineMethodScope() ||
- TopClassStacks.size() == 1 &&
+ assert((CurScope->isInCXXInlineMethodScope() ||
+ TopClassStacks.size() == 1) &&
"MethodLexers not getting popped properly!");
if (CurScope->isInCXXInlineMethodScope())
PopTopClassStack();