Remove reader_get_history

It was unused.
This commit is contained in:
ridiculousfish 2021-10-24 14:17:33 -07:00
parent d03ec2cc6b
commit a6a1879481
2 changed files with 0 additions and 8 deletions

View File

@ -358,8 +358,6 @@ static expand_result_t expand_variables(wcstring instr, completion_receiver_t *o
std::shared_ptr<history_t> history{};
maybe_t<env_var_t> var{};
if (var_name == L"history") {
// Note reader_get_history may return null, if we are running non-interactively (e.g. from
// web_config).
if (is_main_thread()) {
history = history_t::with_name(history_session_id(vars));
}

View File

@ -2872,12 +2872,6 @@ static bool event_is_normal_char(const char_event_t &evt) {
return !fish_reserved_codepoint(c) && c > 31 && c != 127;
}
std::shared_ptr<history_t> reader_get_history() {
ASSERT_IS_MAIN_THREAD();
reader_data_t *data = current_data_or_null();
return data ? data->history : nullptr;
}
/// Run a sequence of commands from an input binding.
void reader_data_t::run_input_command_scripts(const wcstring_list_t &cmds) {
auto last_statuses = parser().get_last_statuses();