Keep running "not --crash" via the external "not" executable, but
for plain negations, and for cases that use the shell "!" operator,
just skip that argument and invert the return code.
The libcxx tests only use the shell operator "!" for negations,
never the "not" executable, because libcxx tests can be run without
having a fully built llvm tree available providing the "not"
executable.
This allows using the internal shell for libcxx tests.
Hello, this logic is not actually sound: There are tests that are sensitive to the specific return code and not just whether the result is zero or not.
From http://lab.llvm.org:8014/#/builders/126/builds/273/steps/5/logs/stdio:
@mstorsjo, please revert if a fix (with an appropriate test) is not forthcoming.