1
1
mirror of https://github.com/mawww/kakoune.git synced 2024-12-26 04:52:53 +03:00

remove useless SelectionList copy in keep

This commit is contained in:
Maxime Coste 2013-07-29 13:51:07 +01:00
parent 4f452474c8
commit c84b861d2f

View File

@ -541,9 +541,8 @@ void keep(Context& context)
regex_prompt(context, prompt, [](const Regex& ex, Context& context) {
Editor& editor = context.editor();
const Buffer& buffer = context.buffer();
SelectionList sels = editor.selections();
SelectionList keep;
for (auto& sel : sels)
for (auto& sel : editor.selections())
{
if (boost::regex_search(buffer.iterator_at(sel.min()),
utf8::next(buffer.iterator_at(sel.max())), ex) == matching)