From c39b94949be30dfbc1c3e271b37ca04cff303b16 Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Sat, 6 Feb 2016 19:17:43 -0800 Subject: Complete to take a pointer to output completions, not a mutable ref --- src/reader.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/reader.cpp') diff --git a/src/reader.cpp b/src/reader.cpp index 900479b2..39bfc0bb 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -1506,7 +1506,7 @@ struct autosuggestion_context_t /* Try normal completions */ std::vector completions; - complete(search_string, completions, COMPLETION_REQUEST_AUTOSUGGESTION); + complete(search_string, &completions, COMPLETION_REQUEST_AUTOSUGGESTION); completions_sort_and_prioritize(&completions); if (! completions.empty()) { @@ -3324,7 +3324,7 @@ const wchar_t *reader_readline(int nchars) const wcstring buffcpy = wcstring(cmdsub_begin, token_end); //fprintf(stderr, "Complete (%ls)\n", buffcpy.c_str()); - data->complete_func(buffcpy, comp, COMPLETION_REQUEST_DEFAULT | COMPLETION_REQUEST_DESCRIPTIONS | COMPLETION_REQUEST_FUZZY_MATCH); + data->complete_func(buffcpy, &comp, COMPLETION_REQUEST_DEFAULT | COMPLETION_REQUEST_DESCRIPTIONS | COMPLETION_REQUEST_FUZZY_MATCH); /* Munge our completions */ completions_sort_and_prioritize(&comp); -- cgit v1.2.3