[PATCH] D26379: [LLD] Fix some Clang-tidy modernize-use-default and Include What You Use warnings; other minor fixes

Rafael EspĂ­ndola via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 8 18:00:16 PST 2016


On 8 November 2016 at 14:02, Eugene Zelenko <eugene.zelenko at gmail.com> wrote:
> Eugene.Zelenko added inline comments.
>
>
> ================
> Comment at: ELF/Target.cpp:35
> +#include "llvm/Object/ELFTypes.h"
> +#include "llvm/Support/Casting.h"
>  #include "llvm/Support/ELF.h"
> ----------------
> rafael wrote:
>> I am not sure how to properly manage this include list if we are going the Include What You Use way. How do we make sure we are not including unnecessary headers?
> Sure, Include What You Use may have false positives and it is not supporting libc++ well. But I manually checked that all added headers are used explicitly.

The question is more: as a developer, how do I keep the list current?
If we stop using StringRef.h somewhere, how do I make sure it is ok to
delete the include? I.E., do we have a "don't include what you don't
use"?

Cheers,
Rafael


More information about the llvm-commits mailing list