From 797a0cb06287d4df5e87b9b49fa535337c9433a7 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Wed, 1 Nov 2017 14:04:42 +0800 Subject: [PATCH] Add another assert to try to catch #1506 --- src/selection.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/selection.cc b/src/selection.cc index d55b3d20c..0ea173ceb 100644 --- a/src/selection.cc +++ b/src/selection.cc @@ -122,6 +122,8 @@ Vector compute_modified_ranges(Buffer& buffer, size_t timestamp) auto forward_end = forward_sorted_until(change_it, changes.end()); auto backward_end = backward_sorted_until(change_it, changes.end()); + kak_assert(std::is_sorted(ranges.begin(), ranges.end(), compare_selections)); + size_t prev_size; size_t dummy = 0; if (forward_end >= backward_end)