Skip to content

Commit

Permalink
compliation fix for macos clang
Browse files Browse the repository at this point in the history
  • Loading branch information
mikolmogorov committed May 24, 2024
1 parent bcf94fa commit b0efd48
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/common/bfcontainer.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ class BFContainer
return *this += -n;
}

BFIterator operator+(difference_type n)
BFIterator operator+(difference_type n) const
{
auto tmp = *this;
return tmp += n;
Expand All @@ -188,13 +188,13 @@ class BFContainer
return rhs + lhs;
}

BFIterator operator-(difference_type n)
BFIterator operator-(difference_type n) const
{
auto tmp = *this;
return tmp -= n;
}

difference_type operator-(const BFIterator& rhs)
difference_type operator-(const BFIterator& rhs) const
{
return difference_type(ChunkSize) * (_map - rhs._map - 1) +
(_chunkCur - _chunkStart) +
Expand Down Expand Up @@ -239,8 +239,8 @@ class BFContainer

T& operator[](difference_type n) {return *(*this += n);}

T& operator*() {return *_chunkCur;}
T* operator->() {return _chunkCur;}
T& operator*() const {return *_chunkCur;}
T* operator->() const {return _chunkCur;}

bool operator==(const BFIterator& rhs) const
{
Expand Down

0 comments on commit b0efd48

Please sign in to comment.