[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15023067#comment-15023067 ] Michael Park commented on MESOS-2275: - {noformat} commit 8e7699af7d35d0d9b64d80183a9e547cc27fb659 Author: Jan SchlichtDate: Mon Nov 23 12:58:47 2015 -0800 Documented C++ include order style. Review: https://reviews.apache.org/r/39449 {noformat} > Document header include rules in style guide > > > Key: MESOS-2275 > URL: https://issues.apache.org/jira/browse/MESOS-2275 > Project: Mesos > Issue Type: Improvement >Reporter: Niklas Quarfot Nielsen >Assignee: Jan Schlicht >Priority: Trivial > Labels: beginner, docathon, mesosphere > > We have several ways of sorting, grouping and ordering headers includes in > Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14968658#comment-14968658 ] Benjamin Bannier commented on MESOS-2275: - I think we probably would also want an example that makes it clearer if in each component we use pure lex sort, or instead do enforce some residual level of logical ordering, e.g. {{clang-format}} (from trunk) prefers lexicographical sort {code} #include #include {code} while one could also imagine the opposite ordering which emphasizes {{foo.hpp}} as some sort of "heading header" (currently not supported by {{clang-format}}). The Google style guide asks for "alphabetical ordering" which isn't helpful here. > Document header include rules in style guide > > > Key: MESOS-2275 > URL: https://issues.apache.org/jira/browse/MESOS-2275 > Project: Mesos > Issue Type: Improvement >Reporter: Niklas Quarfot Nielsen >Assignee: Jan Schlicht >Priority: Trivial > Labels: beginner, docathon, mesosphere > > We have several ways of sorting, grouping and ordering headers includes in > Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14969684#comment-14969684 ] Jan Schlicht commented on MESOS-2275: - The different levels are already separated by newline. `clang-format` will order "include blocks" separately. So its ``` #include #include ``` already. I try to address this in the comment and the example (see the RR). Any suggestions for a better description are always welcome. > Document header include rules in style guide > > > Key: MESOS-2275 > URL: https://issues.apache.org/jira/browse/MESOS-2275 > Project: Mesos > Issue Type: Improvement >Reporter: Niklas Quarfot Nielsen >Assignee: Jan Schlicht >Priority: Trivial > Labels: beginner, docathon, mesosphere > > We have several ways of sorting, grouping and ordering headers includes in > Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14965800#comment-14965800 ] Jan Schlicht commented on MESOS-2275: - Judging from the test cases of the review it should work with clang-format. It'd sort each block locally and treat angle bracket vs. quotes as separate blocks. > Document header include rules in style guide > > > Key: MESOS-2275 > URL: https://issues.apache.org/jira/browse/MESOS-2275 > Project: Mesos > Issue Type: Improvement >Reporter: Niklas Quarfot Nielsen >Assignee: Jan Schlicht >Priority: Trivial > Labels: beginner, docathon, mesosphere > > We have several ways of sorting, grouping and ordering headers includes in > Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14964527#comment-14964527 ] Cody Maloney commented on MESOS-2275: - Out of curiosity, does this format match any of the formats available in clang-format --sort-includes? (http://reviews.llvm.org/D11240) > Document header include rules in style guide > > > Key: MESOS-2275 > URL: https://issues.apache.org/jira/browse/MESOS-2275 > Project: Mesos > Issue Type: Improvement >Reporter: Niklas Quarfot Nielsen >Assignee: Jan Schlicht >Priority: Trivial > Labels: beginner, docathon, mesosphere > > We have several ways of sorting, grouping and ordering headers includes in > Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14294040#comment-14294040 ] Cody Maloney commented on MESOS-2275: - I'd suggest using http://clang.llvm.org/extra/clang-tidy.html to implement a great many more of the rules. If we want to try enforcing more of the Google style guide ruleset, that tool has a whole bunch built in Document header include rules in style guide Key: MESOS-2275 URL: https://issues.apache.org/jira/browse/MESOS-2275 Project: Mesos Issue Type: Improvement Reporter: Niklas Quarfot Nielsen Priority: Trivial Labels: beginner We have several ways of sorting, grouping and ordering headers includes in Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (MESOS-2275) Document header include rules in style guide
[ https://issues.apache.org/jira/browse/MESOS-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14294081#comment-14294081 ] Alexander Rukletsov commented on MESOS-2275: I would prefer to pick up a scheme that saves newlines and is easy to check and automate. Grouping includes by standard+stl, stout, libprocess, mesos and sorting alphabetically inside groups seems to be the easiest solution to me. Document header include rules in style guide Key: MESOS-2275 URL: https://issues.apache.org/jira/browse/MESOS-2275 Project: Mesos Issue Type: Improvement Reporter: Niklas Quarfot Nielsen Priority: Trivial Labels: beginner We have several ways of sorting, grouping and ordering headers includes in Mesos. We should agree on a rule set and do a style scan. -- This message was sent by Atlassian JIRA (v6.3.4#6332)