diff options
author | Bill Wendling <isanbard@gmail.com> | 2008-05-10 10:58:07 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2008-05-10 10:58:07 +0000 |
commit | d2a5a2ae2e45c7dbec84b9df6fe642b41ff5e4e8 (patch) | |
tree | 6bc2eaf458ba1404d3b5ca9288a702aea3bc5c26 /include/llvm/Instructions.h | |
parent | 469a58283023de8e1837932a85d06f2041e30932 (diff) | |
download | external_llvm-d2a5a2ae2e45c7dbec84b9df6fe642b41ff5e4e8.zip external_llvm-d2a5a2ae2e45c7dbec84b9df6fe642b41ff5e4e8.tar.gz external_llvm-d2a5a2ae2e45c7dbec84b9df6fe642b41ff5e4e8.tar.bz2 |
Prevent warnings from the -Wshorten-64-to-32 flag.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50946 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Instructions.h')
-rw-r--r-- | include/llvm/Instructions.h | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/include/llvm/Instructions.h b/include/llvm/Instructions.h index 86bc3f5..b26eb3a 100644 --- a/include/llvm/Instructions.h +++ b/include/llvm/Instructions.h @@ -1683,12 +1683,9 @@ public: return new(3) BranchInst(IfTrue, IfFalse, Cond, InsertAtEnd); } - ~BranchInst() - { + ~BranchInst() { if (NumOperands == 1) - { - NumOperands = (Use*)this - OperandList; - } + NumOperands = (unsigned)(uintptr_t)((Use*)this - OperandList); } /// Transparently provide more efficient getOperand methods. |