[PATCH] D67843: DisableFormat also now disables SortIncludes

Sam Maier via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 23 12:13:27 PDT 2019


SamMaier added a comment.

In D67843#1679529 <https://reviews.llvm.org/D67843#1679529>, @thakis wrote:

> 4. Make it so that if DisableFormat is explicitly set to true and SortIncludes isn't explicitly set, then it disables SortIncludes. Or, put a different way, when DisableFormat is set, set SortIncludes to false at that point. Then an explicit `DisableFormat: true; SortIncludes: true` would still work.
>
>   MyDeveloperDay, would you find that intuitive?
>
>   I think the patch as-is is fine as I said, but if folks want to sort includes without formatting, that might be another option.


I wasn't sure about this since I didn't see any way of distinguishing an explicitly set Style attribute vs an inherited Style attribute from a BasedOnStyle. If there's an easy way to distinguish those two, I'm sure this is the preferred method.


Repository:
  rC Clang

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

https://reviews.llvm.org/D67843





More information about the cfe-commits mailing list