1
1
mirror of https://github.com/mawww/kakoune.git synced 2024-12-23 19:46:33 +03:00

Line completion: sort and uniquify lines

This commit is contained in:
Maxime Coste 2013-08-06 11:35:38 +02:00
parent 9148b1ae92
commit 535a454349

View File

@ -737,6 +737,8 @@ public:
} }
if (res.empty()) if (res.empty())
return {}; return {};
std::sort(res.begin(), res.end());
res.erase(std::unique(res.begin(), res.end()), res.end());
return { cursor_pos.line, cursor_pos, std::move(res), buffer.timestamp() }; return { cursor_pos.line, cursor_pos, std::move(res), buffer.timestamp() };
} }