mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-26 11:01:16 -03:00
Try to rationalize universal variable syncing
Prior to this commit, setting a universal variable may trigger syncing against the file which will modify other universal variables. But if we want to support multiple environments we need the parser to decide when to sync uvars. Shift the decision of when to sync to the parser itself. When a universal variable is modified, now we just set a flag and it's up to the (main) parser when to pick it up. This is hopefully just a refactoring with no user-visible changes.
This commit is contained in:
@@ -351,6 +351,10 @@ void inputter_t::select_interrupted() /* override */ {
|
||||
this->push_front(char_event_t{char_event_type_t::check_exit});
|
||||
}
|
||||
|
||||
void inputter_t::uvar_change_notified() /* override */ {
|
||||
this->parser_->sync_uvars_and_fire(true /* always */);
|
||||
}
|
||||
|
||||
void inputter_t::function_push_arg(wchar_t arg) { input_function_args_.push_back(arg); }
|
||||
|
||||
wchar_t inputter_t::function_pop_arg() {
|
||||
|
||||
Reference in New Issue
Block a user