Minor code cleanup in insert_completer.cc

This commit is contained in:
Maxime Coste 2015-10-30 13:07:48 +00:00
parent 32b51e2cc3
commit 34d7bdbc01

View File

@ -98,11 +98,10 @@ InsertCompletion complete_word(const Buffer& buffer, ByteCoord cursor_pos)
RankedMatchAndBuffer(const RankedMatch& m, const Buffer* b = nullptr)
: RankedMatch{m}, buffer{b} {}
using RankedMatch::operator==;
using RankedMatch::operator<;
bool operator==(StringView other) const { return candidate() == other; }
bool operator==(const RankedMatchAndBuffer& other) const { return RankedMatch::operator==(other); }
bool operator<(const RankedMatchAndBuffer& other) const { return RankedMatch::operator<(other);; }
const Buffer* buffer;
};
Vector<RankedMatchAndBuffer> matches;