summaryrefslogtreecommitdiff
path: root/src/buffer_utils.hh
diff options
context:
space:
mode:
authorMaxime Coste <mawww@kakoune.org>2021-09-29 21:28:30 +1000
committerMaxime Coste <mawww@kakoune.org>2021-09-30 20:12:58 +1000
commit5f8753caec8b9aba8e9793dab972d80a2f222d60 (patch)
tree4a4942df65c9ed6974455ef74eddd755c225a1d3 /src/buffer_utils.hh
parent05fb07fbc6c3a9fcccd69b03b01bf063f524868b (diff)
rework selection insert/replace using a for_each method
expose that method so that various commands can take advantage of it for performance or simplicity purposes.
Diffstat (limited to 'src/buffer_utils.hh')
-rw-r--r--src/buffer_utils.hh5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/buffer_utils.hh b/src/buffer_utils.hh
index a3f18fe1..e0b40425 100644
--- a/src/buffer_utils.hh
+++ b/src/buffer_utils.hh
@@ -20,11 +20,6 @@ inline BufferCoord erase(Buffer& buffer, const Selection& range)
return buffer.erase(range.min(), buffer.char_next(range.max()));
}
-inline BufferRange replace(Buffer& buffer, const Selection& range, StringView content)
-{
- return buffer.replace(range.min(), buffer.char_next(range.max()), content);
-}
-
void replace(Buffer& buffer, ArrayView<BufferRange> ranges, ConstArrayView<String> strings);
inline CharCount char_length(const Buffer& buffer, const Selection& range)