From 0f362b4bb28bc53324aa613096098a53a044e5bb Mon Sep 17 00:00:00 2001 From: Fabian Homborg Date: Sun, 5 Jan 2020 15:44:05 +0100 Subject: [PATCH] Change c{begin,end} to begin,end Unfortunately old distributions are old. Fixes build failures on GCC 4.8 (RHEL6/7). --- src/complete.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/complete.cpp b/src/complete.cpp index 272d63869..128e591b0 100644 --- a/src/complete.cpp +++ b/src/complete.cpp @@ -1680,8 +1680,9 @@ wcstring complete_print() { // Get a list of all completions in a vector, then sort it by order. std::vector> all_completions; - all_completions.insert(all_completions.cbegin(), completion_set->cbegin(), - completion_set->cend()); + // These should be "c"begin/end, but then gcc from ~~the dark ages~~ RHEL 7 would complain. + all_completions.insert(all_completions.begin(), completion_set->begin(), + completion_set->end()); sort(all_completions.begin(), all_completions.end(), compare_completions_by_order); for (const completion_entry_t &e : all_completions) {