Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYuri Gorshenin <y@maps.me>2016-07-18 16:39:49 +0300
committerYuri Gorshenin <y@maps.me>2016-07-22 14:08:44 +0300
commit32af6db6fd63955565a2b26533eb9015ec2f1b56 (patch)
treeb5434fc9024c6039e3bc888e7c31ac253ec5b14e /coding/succinct_mapper.hpp
parent9c128b3a9f250acefae6c213e6410b9a0cd2368c (diff)
[indexer] Implemented CentersTable.
Diffstat (limited to 'coding/succinct_mapper.hpp')
-rw-r--r--coding/succinct_mapper.hpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/coding/succinct_mapper.hpp b/coding/succinct_mapper.hpp
index 30d413f732..e6f856bbc6 100644
--- a/coding/succinct_mapper.hpp
+++ b/coding/succinct_mapper.hpp
@@ -21,7 +21,7 @@ static T * Align8Ptr(T * ptr)
inline uint32_t ToAlign8(uint64_t written) { return (0x8 - (written & 0x7)) & 0x7; }
-inline bool IsAligned(uint64_t offset) { return ToAlign8(offset) == 0; }
+inline bool IsAlign8(uint64_t offset) { return ToAlign8(offset) == 0; }
template <typename TWriter>
void WritePadding(TWriter & writer, uint64_t & bytesWritten)
@@ -139,7 +139,7 @@ public:
typename enable_if<!is_pod<T>::value, FreezeVisitor &>::type operator()(T & val,
char const * /* name */)
{
- ASSERT(IsAligned(m_writer.Pos()), ());
+ ASSERT(IsAlign8(m_writer.Pos()), ());
val.map(*this);
return *this;
}
@@ -148,7 +148,7 @@ public:
typename enable_if<is_pod<T>::value, FreezeVisitor &>::type operator()(T & val,
char const * /* name */)
{
- ASSERT(IsAligned(m_writer.Pos()), ());
+ ASSERT(IsAlign8(m_writer.Pos()), ());
m_writer.Write(&val, sizeof(T));
m_bytesWritten += sizeof(T);
WritePadding(m_writer, m_bytesWritten);
@@ -158,7 +158,7 @@ public:
template <typename T>
FreezeVisitor & operator()(succinct::mapper::mappable_vector<T> & vec, char const * /* name */)
{
- ASSERT(IsAligned(m_writer.Pos()), ());
+ ASSERT(IsAlign8(m_writer.Pos()), ());
(*this)(vec.m_size, "size");
size_t const bytes = static_cast<size_t>(vec.m_size * sizeof(T));
@@ -187,7 +187,7 @@ public:
typename enable_if<!is_pod<T>::value, ReverseFreezeVisitor &>::type operator()(
T & val, char const * /* name */)
{
- ASSERT(IsAligned(m_writer.Pos()), ());
+ ASSERT(IsAlign8(m_writer.Pos()), ());
val.map(*this);
return *this;
}
@@ -196,7 +196,7 @@ public:
typename enable_if<is_pod<T>::value, ReverseFreezeVisitor &>::type operator()(
T & val, char const * /* name */)
{
- ASSERT(IsAligned(m_writer.Pos()), ());
+ ASSERT(IsAlign8(m_writer.Pos()), ());
T const reversedVal = ReverseByteOrder(val);
m_writer.Write(&reversedVal, sizeof(reversedVal));
m_bytesWritten += sizeof(T);
@@ -208,7 +208,7 @@ public:
ReverseFreezeVisitor & operator()(succinct::mapper::mappable_vector<T> & vec,
char const * /* name */)
{
- ASSERT(IsAligned(m_writer.Pos()), ());
+ ASSERT(IsAlign8(m_writer.Pos()), ());
(*this)(vec.m_size, "size");
for (auto const & val : vec)