[cfe-dev] Any objections to re-sorting #include lines with clang-format/clang-tidy?

Nico Weber via cfe-dev cfe-dev at lists.llvm.org
Fri Mar 11 17:05:27 PST 2016


When I brought this up, I think the recommendation was to put these into
separate include groups (i.e. add a newline between atlbase.h and windows.h
-- and the DIA headers are already in a separate block). That seems like a
good approach to me.

On Fri, Mar 11, 2016 at 4:20 AM, Chandler Carruth via cfe-dev <
cfe-dev at lists.llvm.org> wrote:

> Yes, anything like this would be a bug in the logic and I'll file it
> rather than submit it.
>
> On Fri, Mar 11, 2016 at 10:18 AM Ismail Donmez via cfe-dev <
> cfe-dev at lists.llvm.org> wrote:
>
>> On Fri, Mar 11, 2016 at 11:14 AM, Chandler Carruth via cfe-dev
>> <cfe-dev at lists.llvm.org> wrote:
>> > The crazy clang-format folks have taught it to sort includes, and
>> clang-tidy
>> > has a nice way to run it across all of LLVM and Clang.
>> >
>> > Before I just submit the fixes (and any bug reports to the clang-format
>> > folks if it sorts things weirdly) I wanted to double check that folks
>> would
>> > be ok with this. My understanding is that the sorting should match the
>> LLVM
>> > conventions, but if not, I'll make sure to get that fixed first.
>>
>> Should take care of windows headers, part of DIASupport.h:
>>
>> // atlbase.h has to come before windows.h
>> #include <atlbase.h>
>> #include <windows.h>
>>
>> // DIA headers must come after windows headers.
>>                                                    #include
>> <cvconst.h>
>> #include <dia2.h>
>>
>> Sorting those would break stuff.
>> _______________________________________________
>> cfe-dev mailing list
>> cfe-dev at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>>
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20160311/a029e6b5/attachment-0001.html>


More information about the cfe-dev mailing list