From 6e3231a9d705ee043cf827b22c807b0b96ea8893 Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Mon, 27 Jul 2015 18:45:47 -0700 Subject: Stop passing mutable references to completions around Replace uses of vector& with vector* This makes it clear at the call site that the object may be mutated. --- src/fish_tests.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/fish_tests.cpp') diff --git a/src/fish_tests.cpp b/src/fish_tests.cpp index c56593fe..b245dc60 100644 --- a/src/fish_tests.cpp +++ b/src/fish_tests.cpp @@ -739,7 +739,7 @@ static void test_parser() say(L"Testing eval_args"); completion_list_t comps; - parser_t::principal_parser().expand_argument_list(L"alpha 'beta gamma' delta", comps); + parser_t::principal_parser().expand_argument_list(L"alpha 'beta gamma' delta", &comps); do_test(comps.size() == 3); do_test(comps.at(0).completion == L"alpha"); do_test(comps.at(1).completion == L"beta gamma"); @@ -1344,7 +1344,7 @@ static bool expand_test(const wchar_t *in, expand_flags_t flags, ...) wchar_t *arg; parse_error_list_t errors; - if (expand_string(in, output, flags, &errors) == EXPAND_ERROR) + if (expand_string(in, &output, flags, &errors) == EXPAND_ERROR) { if (errors.empty()) { @@ -1583,7 +1583,7 @@ static void test_pager_navigation() completion_list_t completions; for (size_t i=0; i < 19; i++) { - append_completion(completions, L"abcdefghij"); + append_completion(&completions, L"abcdefghij"); } pager_t pager; -- cgit v1.2.3