Make it even more portable.
authorJeff Cohen <jeffc@jolt-lang.org>
Wed, 25 Jan 2006 17:18:50 +0000 (17:18 +0000)
committerJeff Cohen <jeffc@jolt-lang.org>
Wed, 25 Jan 2006 17:18:50 +0000 (17:18 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25605 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Bytecode/Reader/Reader.cpp
lib/CodeGen/DwarfWriter.cpp

index 239cf5c20e9a1d2ac19aad0289e4c5d46eee6ce5..d2660e3faba0759af0c168b58385a967802dd954 100644 (file)
@@ -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 *)((size_t)(At+3) & (~3UL));
+    At = (const unsigned char *)((intptr_t)(At+3) & (~3UL));
     if (At > Save)
       if (Handler) Handler->handleAlignment(At - Save);
     if (At > BlockEnd)
index 888c7717057b7fe0e588eb595fcce2c96839826f..c11c52f08c0c11a264421dfae4657bc5bf372045 100644 (file)
@@ -645,7 +645,7 @@ void DIEAbbrev::Emit(const DwarfWriter &DW) const {
 #ifndef NDEBUG
   void DIEAbbrev::print(std::ostream &O) {
     O << "Abbreviation @"
-      << std::hex << (size_t)this << std::dec
+      << std::hex << (intptr_t)this << std::dec
       << "  "
       << TagString(Tag)
       << " "