summaryrefslogtreecommitdiffstats
path: root/indexlib/memvector.h
diff options
context:
space:
mode:
Diffstat (limited to 'indexlib/memvector.h')
-rw-r--r--indexlib/memvector.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/indexlib/memvector.h b/indexlib/memvector.h
index d4cc446ef..446fddf92 100644
--- a/indexlib/memvector.h
+++ b/indexlib/memvector.h
@@ -72,23 +72,23 @@ struct memory_iterator : public std::iterator<STD_NAMESPACE_PREFIX random_access
}
memory_iterator& operator ++() {
- data_ += byte_io::byte_lenght<T>();
+ data_ += byte_io::byte_length<T>();
return *this;
}
memory_iterator& operator --() {
- data_ -= byte_io::byte_lenght<T>();
+ data_ -= byte_io::byte_length<T>();
return *this;
}
memory_iterator& operator += ( ptrdiff_t dif ) {
- data_ += dif * byte_io::byte_lenght<T>();
+ data_ += dif * byte_io::byte_length<T>();
return *this;
}
ptrdiff_t operator - ( const memory_iterator<T>& other ) const {
- assert( !( ( raw() - other.raw() )%byte_io::byte_lenght<T>() ) );
- return ( raw() - other.raw() )/byte_io::byte_lenght<T>();
+ assert( !( ( raw() - other.raw() )%byte_io::byte_length<T>() ) );
+ return ( raw() - other.raw() )/byte_io::byte_length<T>();
}
bool operator < ( const memory_iterator<T>& other ) const {
@@ -211,8 +211,8 @@ struct memvector {
boost::scoped_ptr<memory_manager> data_;
unsigned char* address_of( unsigned i ) {
return data_->rw_base(
- byte_io::byte_lenght<unsigned>() +
- i * byte_io::byte_lenght<T>() );
+ byte_io::byte_length<unsigned>() +
+ i * byte_io::byte_length<T>() );
}
const unsigned char* address_of( unsigned i ) const {
return const_cast<memvector*>( this )->address_of( i );