mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-20 22:21:16 -03:00
Improve codegen of generation_list_t::operator==
Bizarrely comparing three integers showed up heavy in traces. This reduces the time in seq_echo by about 500 msec.
This commit is contained in:
@@ -107,7 +107,10 @@ class generation_list_t {
|
||||
return valid;
|
||||
}
|
||||
|
||||
bool operator==(const generation_list_t &rhs) const { return as_array() == rhs.as_array(); }
|
||||
bool operator==(const generation_list_t &rhs) const {
|
||||
return sighupint == rhs.sighupint && sigchld == rhs.sigchld &&
|
||||
internal_exit == rhs.internal_exit;
|
||||
}
|
||||
|
||||
bool operator!=(const generation_list_t &rhs) const { return !(*this == rhs); }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user