In some cases on some platforms this could clobber errno, so doing something like
aThingThatFailsWithErrno();
FLOG(category, "Some message");
wperror("something");
would print the wrong error (presumably if that category was enabled).
In our case it was our (very) old friend RHEL6 returning ESPIPE instead of EISDIR.
Fixes#6545.
Improve the iothread behavior by enabling an iothread to stick around for
a while waiting for work. This reduces the amount of iothread churn, which
is useful on platforms where threads are expensive.
Also do other modernization like clean up the locking discipline and use
FLOG.
This adds support for `fish_trace`, a new variable intended to serve the
same purpose as `set -x` as in bash. Setting this variable to anything
non-empty causes execution to be traced. In the future we may give more
specific meaning to the value of the variable.
The user's prompt is not traced unless you run it explicitly. Events are
also not traced because it is noisy; however autoloading is.
Fixes#3427
This adds a new mechanism for logging, intended to replace debug().
The entry points are FLOG and FLOGF. FLOG can be used to log a sequence of
arguments, FLOGF is for printf-style formatted strings.
Each call to FLOG and FLOGF requires a category. If logging for a category
is not enabled, there is no effect (and arguments are not evaluated).
Categories may be enabled on the command line via the -d option.