summaryrefslogtreecommitdiff
path: root/src/buffer.cc
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2016-03-08 21:35:56 +0000
committerMaxime Coste <frrrwww@gmail.com>2016-03-08 21:35:56 +0000
commit9e15181dc9b56435c5e1d3ab87dd03404d6c31c9 (patch)
tree2fcf0f09cea4755e36c7295b517676a234c10c51 /src/buffer.cc
parent21ae66215163976ea4c826dcdf55e04ddce54748 (diff)
Rework container helpers, use pipe syntax and cleanup implementation
use 'container | filter(func) | reverse() | transform(func)' instead of 'transform(reverse(filter(container), func), func)' to express container transformations.
Diffstat (limited to 'src/buffer.cc')
-rw-r--r--src/buffer.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/buffer.cc b/src/buffer.cc
index e140f333..c0e25f0a 100644
--- a/src/buffer.cc
+++ b/src/buffer.cc
@@ -304,7 +304,7 @@ bool Buffer::undo()
--m_history_cursor;
- for (const Modification& modification : reversed(*m_history_cursor))
+ for (const Modification& modification : *m_history_cursor | reverse())
apply_modification(modification.inverse());
return true;
}