aboutsummaryrefslogtreecommitdiff
path: root/common/stream.h
diff options
context:
space:
mode:
authorBastien Bouclet2017-09-24 18:19:29 +0200
committerBastien Bouclet2017-09-30 21:35:16 +0200
commit86573a8eaf477324e836782dfe3ec8ee5a65d28f (patch)
treee12f6e6ea0619864ac55776931bbe9c18d41826d /common/stream.h
parentf800783767d22ab8863f026f0125ff95dedf0cf5 (diff)
downloadscummvm-rg350-86573a8eaf477324e836782dfe3ec8ee5a65d28f.tar.gz
scummvm-rg350-86573a8eaf477324e836782dfe3ec8ee5a65d28f.tar.bz2
scummvm-rg350-86573a8eaf477324e836782dfe3ec8ee5a65d28f.zip
COMMON: Unconditionally enable 64 bit integer features
Diffstat (limited to 'common/stream.h')
-rw-r--r--common/stream.h20
1 files changed, 0 insertions, 20 deletions
diff --git a/common/stream.h b/common/stream.h
index 6932c7d2d0..fed81c9192 100644
--- a/common/stream.h
+++ b/common/stream.h
@@ -133,12 +133,10 @@ public:
write(&value, 4);
}
-#ifdef HAVE_INT64
void writeUint64LE(uint64 value) {
value = TO_LE_64(value);
write(&value, 8);
}
-#endif
void writeUint16BE(uint16 value) {
value = TO_BE_16(value);
@@ -150,12 +148,10 @@ public:
write(&value, 4);
}
-#ifdef HAVE_INT64
void writeUint64BE(uint64 value) {
value = TO_BE_64(value);
write(&value, 8);
}
-#endif
FORCEINLINE void writeSint16LE(int16 value) {
writeUint16LE((uint16)value);
@@ -165,11 +161,9 @@ public:
writeUint32LE((uint32)value);
}
-#ifdef HAVE_INT64
FORCEINLINE void writeSint64LE(int64 value) {
writeUint64LE((uint64)value);
}
-#endif
FORCEINLINE void writeSint16BE(int16 value) {
writeUint16BE((uint16)value);
@@ -179,11 +173,9 @@ public:
writeUint32BE((uint32)value);
}
-#ifdef HAVE_INT64
FORCEINLINE void writeSint64BE(int64 value) {
writeUint64BE((uint64)value);
}
-#endif
/**
@@ -301,7 +293,6 @@ public:
return FROM_LE_32(val);
}
-#ifdef HAVE_INT64
/**
* Read an unsigned 64-bit word stored in little endian (LSB first) order
* from the stream and return it.
@@ -314,7 +305,6 @@ public:
read(&val, 8);
return FROM_LE_64(val);
}
-#endif
/**
* Read an unsigned 16-bit word stored in big endian (MSB first) order
@@ -342,7 +332,6 @@ public:
return FROM_BE_32(val);
}
-#ifdef HAVE_INT64
/**
* Read an unsigned 64-bit word stored in big endian (MSB first) order
* from the stream and return it.
@@ -355,7 +344,6 @@ public:
read(&val, 8);
return FROM_BE_64(val);
}
-#endif
/**
* Read a signed 16-bit word stored in little endian (LSB first) order
@@ -379,7 +367,6 @@ public:
return (int32)readUint32LE();
}
-#ifdef HAVE_INT64
/**
* Read a signed 64-bit word stored in little endian (LSB first) order
* from the stream and return it.
@@ -390,7 +377,6 @@ public:
FORCEINLINE int64 readSint64LE() {
return (int64)readUint64LE();
}
-#endif
/**
* Read a signed 16-bit word stored in big endian (MSB first) order
@@ -414,7 +400,6 @@ public:
return (int32)readUint32BE();
}
-#ifdef HAVE_INT64
/**
* Read a signed 64-bit word stored in big endian (MSB first) order
* from the stream and return it.
@@ -425,7 +410,6 @@ public:
FORCEINLINE int64 readSint64BE() {
return (int64)readUint64BE();
}
-#endif
/**
* Read a 32-bit floating point value stored in little endian (LSB first)
@@ -600,13 +584,11 @@ public:
return (_bigEndian) ? TO_BE_32(val) : TO_LE_32(val);
}
-#ifdef HAVE_INT64
uint64 readUint64() {
uint64 val;
read(&val, 8);
return (_bigEndian) ? TO_BE_64(val) : TO_LE_64(val);
}
-#endif
FORCEINLINE int16 readSint16() {
return (int16)readUint16();
@@ -616,11 +598,9 @@ public:
return (int32)readUint32();
}
-#ifdef HAVE_INT64
FORCEINLINE int64 readSint64() {
return (int64)readUint64();
}
-#endif
};
/**