Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(326)

Issue 1213113004: Improve the diagnostics for include order presubmit checks (Closed)

Created:
5 years, 5 months ago by brucedawson
Modified:
5 years, 5 months ago
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Improve the diagnostics for include order presubmit checks The information given by the presubmit checks when an include error violation is found is not always the clearest, especially to a new Chrome developer. The rules for determining which group a header file goes into are not immediately obvious and the warnings don't say whether the problem is a sort order or a group order. This change adds that information. It also puts the URL on a separate line for easier selection, especially important on Windows. The old output looks like this: ** Presubmit Messages ** Your #include order seems to be broken. Remember to use the right collation (LC_COLLATE=C) and check https://google-styleguide.googlecode.com m/svn/trunk/cppguide.html#Names_and_Order_of_Includes chrome\browser\task_manager\task_manager.cc:10 \ chrome\browser\task_manager\task_manager.cc:11 The new output looks like this: ** Presubmit Messages ** Your #include order seems to be broken. Remember to use the right collation (LC_COLLATE=C) and check https://google-styleguide.googlecode.com/svn/trunk/cppguide.html#Names_and_Order_of_Includes chrome\browser\task_manager\task_manager.cc:10: - c++ system include file in wrong block \ chrome\browser\task_manager\task_manager.cc:11: - line belongs before previous line Notice the explanations for why a line is highlighted, and the non-wordwrapped URL. R=maruel@chromium.org Committed: https://crrev.com/70fadb041abae3242d2c00066ff806f47a98aecc Cr-Commit-Position: refs/heads/master@{#336813}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+14 lines, -9 lines) Patch
M PRESUBMIT.py View 2 chunks +14 lines, -9 lines 0 comments Download

Messages

Total messages: 9 (2 generated)
brucedawson
How does this change look? It would have saved me a lot of time and ...
5 years, 5 months ago (2015-06-29 23:17:30 UTC) #1
Marc-Antoine Ruel (Google)
Redirecting as I'm not an owner anymore.
5 years, 5 months ago (2015-06-29 23:35:43 UTC) #3
jochen (gone - plz use gerrit)
lgtm
5 years, 5 months ago (2015-06-30 07:58:47 UTC) #4
Paweł Hajdan Jr.
LGTM
5 years, 5 months ago (2015-06-30 07:58:56 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1213113004/1
5 years, 5 months ago (2015-06-30 17:33:30 UTC) #7
commit-bot: I haz the power
Committed patchset #1 (id:1)
5 years, 5 months ago (2015-06-30 17:48:03 UTC) #8
commit-bot: I haz the power
5 years, 5 months ago (2015-06-30 17:48:54 UTC) #9
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/70fadb041abae3242d2c00066ff806f47a98aecc
Cr-Commit-Position: refs/heads/master@{#336813}

Powered by Google App Engine
This is Rietveld 408576698