diff options
| author | Hans Wennborg <hans@hanshq.net> | 2013-08-09 16:48:21 +0000 |
|---|---|---|
| committer | Hans Wennborg <hans@hanshq.net> | 2013-08-09 16:48:21 +0000 |
| commit | 735d0dcccff0eb1e3ba8f353495a25640e836e0c (patch) | |
| tree | 96944e42232795d385ea30b7bda70db9f5a814b1 | |
| parent | ec2f90c025046fc1a4008f707866441c101d773d (diff) | |
| download | bcm5719-llvm-735d0dcccff0eb1e3ba8f353495a25640e836e0c.tar.gz bcm5719-llvm-735d0dcccff0eb1e3ba8f353495a25640e836e0c.zip | |
ELFObjectFile.h: Silence warning on Windows
The compiler was warning about using | on a uintptr_t and bool:
Object/ELFObjectFile.h(131) : warning C4805: '|' : unsafe
mix of type 'uintptr_t' and type 'bool' in operation
I think the warning might be useful in other cases, so I added
a cast instead of disabling it altogether.
llvm-svn: 188079
| -rw-r--r-- | llvm/include/llvm/Object/ELFObjectFile.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/include/llvm/Object/ELFObjectFile.h b/llvm/include/llvm/Object/ELFObjectFile.h index f0be8abb09f..08cac04ac6d 100644 --- a/llvm/include/llvm/Object/ELFObjectFile.h +++ b/llvm/include/llvm/Object/ELFObjectFile.h @@ -128,7 +128,8 @@ protected: // ELF specific protected members. DataRefImpl toDRI(Elf_Sym_Iter Symb) const { DataRefImpl DRI; - DRI.p = reinterpret_cast<uintptr_t>(Symb.get()) | Symb.isDynamic(); + DRI.p = reinterpret_cast<uintptr_t>(Symb.get()) | + static_cast<uintptr_t>(Symb.isDynamic()); return DRI; } |

