diff options
author | Eli Bendersky <eliben@google.com> | 2012-12-18 18:53:14 +0000 |
---|---|---|
committer | Eli Bendersky <eliben@google.com> | 2012-12-18 18:53:14 +0000 |
commit | 6bd120387a0d36bb5a748d4100b3eaa399eb53c5 (patch) | |
tree | 094bed6374c61deeeb270a9fbdad794cb66891a2 /lib/CodeGen/CGRecordLayoutBuilder.cpp | |
parent | b13621d08e20ac7aa550e05896de8a57ee99c1e8 (diff) |
Fix a compilation warning with gcc 4.6
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@170440 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGRecordLayoutBuilder.cpp')
-rw-r--r-- | lib/CodeGen/CGRecordLayoutBuilder.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/CGRecordLayoutBuilder.cpp b/lib/CodeGen/CGRecordLayoutBuilder.cpp index 43088b4a20..90c3387029 100644 --- a/lib/CodeGen/CGRecordLayoutBuilder.cpp +++ b/lib/CodeGen/CGRecordLayoutBuilder.cpp @@ -1088,7 +1088,7 @@ CGRecordLayout *CodeGenTypes::ComputeRecordLayout(const RecordDecl *D, "Storage size does not match the element type size"); } assert(Info.Size > 0 && "Empty bitfield!"); - assert(Info.Offset + Info.Size <= Info.StorageSize && + assert(static_cast<unsigned>(Info.Offset) + Info.Size <= Info.StorageSize && "Bitfield outside of its allocated storage"); } #endif |