diff options
author | David Greene <greened@obbligato.org> | 2013-01-15 23:13:49 +0000 |
---|---|---|
committer | David Greene <greened@obbligato.org> | 2013-01-15 23:13:49 +0000 |
commit | ed6355d56cbeb1cd1a77cc46e0a519af25523ccb (patch) | |
tree | 123ba6b09dec944fbdde157d268e381b54570886 /lib/CodeGen/CGRecordLayoutBuilder.cpp | |
parent | cc41a94688615b551505e0e7c287e1c444f53a3f (diff) |
Fix signed/unsigned Compare
Do some casting to avoid a signed/unsigned compare.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172571 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGRecordLayoutBuilder.cpp')
-rw-r--r-- | lib/CodeGen/CGRecordLayoutBuilder.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/CodeGen/CGRecordLayoutBuilder.cpp b/lib/CodeGen/CGRecordLayoutBuilder.cpp index 1d7271d6a4..02920cd9b6 100644 --- a/lib/CodeGen/CGRecordLayoutBuilder.cpp +++ b/lib/CodeGen/CGRecordLayoutBuilder.cpp @@ -1075,7 +1075,8 @@ CGRecordLayout *CodeGenTypes::ComputeRecordLayout(const RecordDecl *D, // the size + offset should match the storage size in that case as it // "starts" at the back. if (getDataLayout().isBigEndian()) - assert((Info.Offset + Info.Size) == Info.StorageSize && + assert(static_cast<unsigned>(Info.Offset + Info.Size) == + Info.StorageSize && "Big endian union bitfield does not end at the back"); else assert(Info.Offset == 0 && |