[PATCH] D85788: [Clang test] Update to allow passing extra default clang arguments in use_clang

Juneyoung Lee via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 11 10:49:20 PST 2020


aqjune added a comment.

In D85788#2444136 <https://reviews.llvm.org/D85788#2444136>, @guiand wrote:

> IMO it's better to just one-and-done programatically add `-Xclang -disable-noundef-analysis` to all the tests' RUN lines. That way there are no hidden flags.

If a script for this can be written and people who are working for the downstream project are happy with the script, this is the best approach IMO. It is clear and explicit.

In D85788#2441457 <https://reviews.llvm.org/D85788#2441457>, @eugenis wrote:

>> This new substitution is going to be used for the noundef checks in D81678 <https://reviews.llvm.org/D81678> only anyway.
>
> I'm not sure what you mean by this. The substitution is used ~380 times in this patch alone.
> In the future, any attempt to use %clang -### or -%clang -cc1as will produce the same unused argument warning, and it is very unclear that is can be fixed with %clang_bin. Note that code search for "-disable-noundef-analysis" does NOT lead you to the definition of %clang_bin!

I see, I was naively thinking the `%clang` -> `%clang_bin` changes were here to simply show that they are equivalent if function signatures are not checked. I thought `%clang` could be still used for those tests.
But they were here because the upcoming patch will otherwise make them raise unused argument warning.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85788/new/

https://reviews.llvm.org/D85788



More information about the cfe-commits mailing list