diff --git a/src/reader.cpp b/src/reader.cpp index 83d4355e8..a49806faf 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -2646,12 +2646,7 @@ static eval_res_t reader_run_command(parser_t &parser, const wcstring &cmd) { return eval_res; } -static parser_test_error_bits_t reader_shell_test(const parser_t &parser, const wcstring &b) { - wcstring bstr = b; - - // Append a newline, to act as a statement terminator. - bstr.push_back(L'\n'); - +static parser_test_error_bits_t reader_shell_test(const parser_t &parser, const wcstring &bstr) { parse_error_list_t errors; parser_test_error_bits_t res = parse_util_detect_errors(bstr, &errors, true /* do accept incomplete */);