remove BufferIterator::is_valid()

This commit is contained in:
Maxime Coste 2013-06-04 18:56:28 +02:00
parent a23aa10797
commit 777158e86d
2 changed files with 1 additions and 8 deletions

View File

@ -62,8 +62,6 @@ public:
BufferIterator& operator=(const BufferCoord& coord); BufferIterator& operator=(const BufferCoord& coord);
operator const BufferCoord&() const { return m_coord; } operator const BufferCoord&() const { return m_coord; }
bool is_valid() const;
const BufferCoord& coord() const { return m_coord; } const BufferCoord& coord() const { return m_coord; }
private: private:

View File

@ -9,12 +9,7 @@ namespace Kakoune
inline BufferIterator::BufferIterator(const Buffer& buffer, BufferCoord coord) inline BufferIterator::BufferIterator(const Buffer& buffer, BufferCoord coord)
: m_buffer(&buffer), m_coord(coord) : m_buffer(&buffer), m_coord(coord)
{ {
kak_assert(is_valid()); kak_assert(m_buffer and m_buffer->is_valid(m_coord));
}
inline bool BufferIterator::is_valid() const
{
return m_buffer and m_buffer->is_valid(m_coord);
} }
inline bool BufferIterator::operator==(const BufferIterator& iterator) const inline bool BufferIterator::operator==(const BufferIterator& iterator) const