[LitConfig] Silenced notes/warnings on quiet.
authorAndrew Trick <atrick@apple.com>
Tue, 8 Oct 2019 01:31:02 +0000 (01:31 +0000)
committerAndrew Trick <atrick@apple.com>
Tue, 8 Oct 2019 01:31:02 +0000 (01:31 +0000)
commitcb194057b9d6d1cd68b3aa98b59c6cb323293d51
treebea60cc4dc0661d46cfdeabe7dd917066927abae
parente21399b02e2651eb461301452355fc821d28712b
[LitConfig] Silenced notes/warnings on quiet.

Lit has a "quiet" option, -q, which is documented to "suppress no
error output". Previously, LitConfig displayed notes and warnings when
the quiet option was specified. The result was that it was not
possible to get only pertinent file/line information to be used by an
editor to jump to the location where checks were failing without
passing a number of unhelpful locations first. Here, the
implementations of LitConfig.note and LitConfig.warning are modified
to account for the quiet flag and avoid displaying if the flag has
indeed been set.

Patch by Nate Chandler

Reviewed by yln

Differential Revision: https://reviews.llvm.org/D68044

llvm-svn: 374009
llvm/utils/lit/lit/LitConfig.py