summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeff Cohen <jeffc@jolt-lang.org>2006-01-25 02:40:10 +0000
committerJeff Cohen <jeffc@jolt-lang.org>2006-01-25 02:40:10 +0000
commita292744ecc585432a5c75c59ae5f7b4823783b38 (patch)
treee8fa1e57f3cfd83595f53dff0a9d594441db9211
parent5ea06a9f139598fdd06a2f988a18c789951074a6 (diff)
downloadbcm5719-llvm-a292744ecc585432a5c75c59ae5f7b4823783b38.tar.gz
bcm5719-llvm-a292744ecc585432a5c75c59ae5f7b4823783b38.zip
Portably cast a pointer to an integer.
llvm-svn: 25594
-rw-r--r--llvm/lib/Bytecode/Reader/Reader.cpp2
-rw-r--r--llvm/lib/CodeGen/DwarfWriter.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Bytecode/Reader/Reader.cpp b/llvm/lib/Bytecode/Reader/Reader.cpp
index e57101aeb57..239cf5c20e9 100644
--- a/llvm/lib/Bytecode/Reader/Reader.cpp
+++ b/llvm/lib/Bytecode/Reader/Reader.cpp
@@ -79,7 +79,7 @@ inline void BytecodeReader::checkPastBlockEnd(const char * block_name) {
inline void BytecodeReader::align32() {
if (hasAlignment) {
BufPtr Save = At;
- At = (const unsigned char *)((unsigned long)(At+3) & (~3UL));
+ At = (const unsigned char *)((size_t)(At+3) & (~3UL));
if (At > Save)
if (Handler) Handler->handleAlignment(At - Save);
if (At > BlockEnd)
diff --git a/llvm/lib/CodeGen/DwarfWriter.cpp b/llvm/lib/CodeGen/DwarfWriter.cpp
index c3958906b61..888c7717057 100644
--- a/llvm/lib/CodeGen/DwarfWriter.cpp
+++ b/llvm/lib/CodeGen/DwarfWriter.cpp
@@ -645,7 +645,7 @@ void DIEAbbrev::Emit(const DwarfWriter &DW) const {
#ifndef NDEBUG
void DIEAbbrev::print(std::ostream &O) {
O << "Abbreviation @"
- << std::hex << (unsigned long)this << std::dec
+ << std::hex << (size_t)this << std::dec
<< " "
<< TagString(Tag)
<< " "
OpenPOWER on IntegriCloud