Bug 210979 - check-webkit-style should recognize *Internal.h and *Private.h as primary headers
Summary: check-webkit-style should recognize *Internal.h and *Private.h as primary hea...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: David Kilzer (:ddkilzer)
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-04-24 10:55 PDT by David Kilzer (:ddkilzer)
Modified: 2020-04-24 11:43 PDT (History)
5 users (show)

See Also:


Attachments
Patch v1 (3.10 KB, patch)
2020-04-24 11:07 PDT, David Kilzer (:ddkilzer)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Kilzer (:ddkilzer) 2020-04-24 10:55:50 PDT
check-webkit-style should recognize *Internal.h and *Private.h as primary headers.

For example, see style bot results from Bug 210974, Attachment #397471 [details]:

ERROR: Source/WebKit/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandle.mm:29:  Alphabetical sorting problem.  [build/include_order] [4]
ERROR: Source/WebKit/UIProcess/API/Cocoa/_WKActivatedElementInfo.mm:29:  Alphabetical sorting problem.  [build/include_order] [4]

<https://ews-build.webkit.org/#/builders/6/builds/19650>
Comment 1 David Kilzer (:ddkilzer) 2020-04-24 11:07:37 PDT
Created attachment 397472 [details]
Patch v1
Comment 2 Darin Adler 2020-04-24 11:09:35 PDT
Comment on attachment 397472 [details]
Patch v1

When making changes like this I like the idea of running check-webkit-style across the whole source tree, but there are probably *so* many messages when doing that, it’s not a great thing.
Comment 3 David Kilzer (:ddkilzer) 2020-04-24 11:16:00 PDT
(In reply to Darin Adler from comment #2)
> Comment on attachment 397472 [details]
> Patch v1
> 
> When making changes like this I like the idea of running check-webkit-style
> across the whole source tree, but there are probably *so* many messages when
> doing that, it’s not a great thing.

You can do that by only running the checker you care about like this:

$ ./Tools/Scripts/check-webkit-style --filter=-,+build/include_order Source Tools

But there still might be^H^H^Hare a lot of build/include_order warnings.  (Too many "WARNING: File exempt from style guide. Skipping: ..." warnings as well.) For example, just running on Source/WebKit:

$ ./Tools/Scripts/check-webkit-style --filter=-,+build/include_order Source/WebKit
[...]
Total errors found: 291 in 3961 files

We probably need to break out "build/include_order" warnings into subcategories like build/include_order/alphabetical_sorting and build/include_order/missing_config_h eventually.
Comment 4 David Kilzer (:ddkilzer) 2020-04-24 11:18:14 PDT
Comment on attachment 397472 [details]
Patch v1

Adding cq+ early since webkitpy tests passed, and this is a change that only affects check-webkit-style.
Comment 5 EWS 2020-04-24 11:42:58 PDT
Committed r260659: <https://trac.webkit.org/changeset/260659>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 397472 [details].
Comment 6 Radar WebKit Bug Importer 2020-04-24 11:43:13 PDT
<rdar://problem/62328013>