summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/BasicStream.cpp
diff options
context:
space:
mode:
authorMarc Laukien <marc@zeroc.com>2002-01-17 18:53:26 +0000
committerMarc Laukien <marc@zeroc.com>2002-01-17 18:53:26 +0000
commitee96d66cf2a5a5b62b5ac01dbe251ba21e7fae96 (patch)
tree20e6b7d2611345407074be079cdb9f6f6cb64904 /cpp/src/Ice/BasicStream.cpp
parentFix bug with location of annotation for some types. (diff)
downloadice-ee96d66cf2a5a5b62b5ac01dbe251ba21e7fae96.tar.bz2
ice-ee96d66cf2a5a5b62b5ac01dbe251ba21e7fae96.tar.xz
ice-ee96d66cf2a5a5b62b5ac01dbe251ba21e7fae96.zip
unicode tests
Diffstat (limited to 'cpp/src/Ice/BasicStream.cpp')
-rw-r--r--cpp/src/Ice/BasicStream.cpp46
1 files changed, 23 insertions, 23 deletions
diff --git a/cpp/src/Ice/BasicStream.cpp b/cpp/src/Ice/BasicStream.cpp
index 4ca75897a87..9d2bc9bf314 100644
--- a/cpp/src/Ice/BasicStream.cpp
+++ b/cpp/src/Ice/BasicStream.cpp
@@ -95,7 +95,7 @@ IceInternal::BasicStream::endWriteEncaps()
}
Int sz = b.size() - start;
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + start - sizeof(Int));
#else
copy(p, p + sizeof(Int), b.begin() + start - sizeof(Int));
@@ -218,7 +218,7 @@ IceInternal::BasicStream::write(const vector<Byte>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz);
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
#else
copy(p, p + sizeof(Int), b.begin() + pos);
@@ -258,7 +258,7 @@ IceInternal::BasicStream::write(const vector<bool>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz);
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
#else
copy(p, p + sizeof(Int), b.begin() + pos);
@@ -297,7 +297,7 @@ IceInternal::BasicStream::write(Short v)
int pos = b.size();
resize(pos + sizeof(Short));
const Byte* p = reinterpret_cast<const Byte*>(&v);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Short), b.begin() + pos);
#else
copy(p, p + sizeof(Short), b.begin() + pos);
@@ -311,7 +311,7 @@ IceInternal::BasicStream::write(const vector<Short>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz * sizeof(Short));
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
pos += sizeof(Int);
p = reinterpret_cast<const Byte*>(v.begin());
@@ -337,7 +337,7 @@ IceInternal::BasicStream::read(Short& v)
{
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(begin, i, reinterpret_cast<Byte*>(&v));
#else
copy(begin, i, reinterpret_cast<Byte*>(&v));
@@ -356,7 +356,7 @@ IceInternal::BasicStream::read(vector<Short>& v)
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
v.resize(sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
for (int j = 0 ; j < sz ; ++j)
{
reverse_copy(begin, begin + sizeof(Short), reinterpret_cast<Byte*>(&v[j]));
@@ -373,7 +373,7 @@ IceInternal::BasicStream::write(Int v)
int pos = b.size();
resize(pos + sizeof(Int));
const Byte* p = reinterpret_cast<const Byte*>(&v);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
#else
copy(p, p + sizeof(Int), b.begin() + pos);
@@ -387,7 +387,7 @@ IceInternal::BasicStream::write(const vector<Int>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz * sizeof(Int));
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
pos += sizeof(Int);
p = reinterpret_cast<const Byte*>(v.begin());
@@ -413,7 +413,7 @@ IceInternal::BasicStream::read(Int& v)
{
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(begin, i, reinterpret_cast<Byte*>(&v));
#else
copy(begin, i, reinterpret_cast<Byte*>(&v));
@@ -432,7 +432,7 @@ IceInternal::BasicStream::read(vector<Int>& v)
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
v.resize(sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
for (int j = 0 ; j < sz ; ++j)
{
reverse_copy(begin, begin + sizeof(Int), reinterpret_cast<Byte*>(&v[j]));
@@ -449,7 +449,7 @@ IceInternal::BasicStream::write(Long v)
int pos = b.size();
resize(pos + sizeof(Long));
const Byte* p = reinterpret_cast<const Byte*>(&v);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Long), b.begin() + pos);
#else
copy(p, p + sizeof(Long), b.begin() + pos);
@@ -463,7 +463,7 @@ IceInternal::BasicStream::write(const vector<Long>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz * sizeof(Long));
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
pos += sizeof(Int);
p = reinterpret_cast<const Byte*>(v.begin());
@@ -489,7 +489,7 @@ IceInternal::BasicStream::read(Long& v)
{
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(begin, i, reinterpret_cast<Byte*>(&v));
#else
copy(begin, i, reinterpret_cast<Byte*>(&v));
@@ -508,7 +508,7 @@ IceInternal::BasicStream::read(vector<Long>& v)
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
v.resize(sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
for (int j = 0 ; j < sz ; ++j)
{
reverse_copy(begin, begin + sizeof(Long), reinterpret_cast<Byte*>(&v[j]));
@@ -525,7 +525,7 @@ IceInternal::BasicStream::write(Float v)
int pos = b.size();
resize(pos + sizeof(Float));
const Byte* p = reinterpret_cast<const Byte*>(&v);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Float), b.begin() + pos);
#else
copy(p, p + sizeof(Float), b.begin() + pos);
@@ -539,7 +539,7 @@ IceInternal::BasicStream::write(const vector<Float>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz * sizeof(Float));
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
pos += sizeof(Int);
p = reinterpret_cast<const Byte*>(v.begin());
@@ -565,7 +565,7 @@ IceInternal::BasicStream::read(Float& v)
{
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(begin, i, reinterpret_cast<Byte*>(&v));
#else
copy(begin, i, reinterpret_cast<Byte*>(&v));
@@ -584,7 +584,7 @@ IceInternal::BasicStream::read(vector<Float>& v)
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
v.resize(sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
for (int j = 0 ; j < sz ; ++j)
{
reverse_copy(begin, begin + sizeof(Float), reinterpret_cast<Byte*>(&v[j]));
@@ -601,7 +601,7 @@ IceInternal::BasicStream::write(Double v)
int pos = b.size();
resize(pos + sizeof(Double));
const Byte* p = reinterpret_cast<const Byte*>(&v);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Double), b.begin() + pos);
#else
copy(p, p + sizeof(Double), b.begin() + pos);
@@ -615,7 +615,7 @@ IceInternal::BasicStream::write(const vector<Double>& v)
Int sz = v.size();
resize(pos + sizeof(Int) + sz * sizeof(Double));
const Byte* p = reinterpret_cast<const Byte*>(&sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(p, p + sizeof(Int), b.begin() + pos);
pos += sizeof(Int);
p = reinterpret_cast<const Byte*>(v.begin());
@@ -641,7 +641,7 @@ IceInternal::BasicStream::read(Double& v)
{
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
reverse_copy(begin, i, reinterpret_cast<Byte*>(&v));
#else
copy(begin, i, reinterpret_cast<Byte*>(&v));
@@ -660,7 +660,7 @@ IceInternal::BasicStream::read(vector<Double>& v)
throw UnmarshalOutOfBoundsException(__FILE__, __LINE__);
}
v.resize(sz);
-#ifdef ICE_BIGENDIAN
+#ifdef ICE_UTIL_BIGENDIAN
for (int j = 0 ; j < sz ; ++j)
{
reverse_copy(begin, begin + sizeof(Double), reinterpret_cast<Byte*>(&v[j]));