Open Bug 2054311 Opened 20 days ago Updated 15 days ago

Sort more headers automatically.

Categories

(Core :: General, enhancement, P3)

enhancement

Tracking

()

ASSIGNED

People

(Reporter: emilio, Assigned: emilio)

References

(Blocks 1 open bug, Regressed 1 open bug)

Details

(Keywords: leave-open)

Attachments

(14 files)

48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review

dom/ and layout/ already sort headers automatically, let's make that the default, as per our coding style.

Automatically generated with:

cp dom/.clang-format media/ && mach format media/**.{cpp,h}

No manual changes required.

Assignee: nobody → emilio
Status: NEW → ASSIGNED

Automatically generated with:

cp dom/.clang-format xpcom/ && mach format xpcom/**.{cpp,h}

No manual changes required.

Autogenerated with:

cp dom/.clang-format widget/ && mach format widget/**.{cpp,h,mm}

Manual changes:

  • Had to add a manual override in nsWaylandDisplay.h.
  • Missing includes in nsWindowWayland/X11.h

Autogenerated with:

cp dom/.clang-format caps/ && mach format caps/**.{cpp,h}

No manual changes required.

Autogenerated with:

cp dom/.clang-format security/ && mach format security/**.{cpp,h,mm}

Manual changes:

  • Missing includes in CRLiteTimestamp.h and AppSignatureVerification.h

Autogenerated with:

cp dom/.clang-format mfbt/ && mach format mfbt/**.{cpp,h,mm}

No manual changes required.

Autogenerated with:

cp dom/.clang-format accessible/ && mach format accessible/**.{cpp,h,mm}

Manual fixes:

  • Atk individual includes need to become atk/atk.h because otherwise some symbols incorrectly get hidden visibility.

Autogenerated by:

cp dom/.clang-format image/ && mach format image/**.{cpp,h,mm}

No manual changes required.

It seems third-party (https://osvr.github.io/). This prevent the
following commit from rewriting those.

Autogenerated with:

cp dom/.clang-format gfx/ && mach format gfx/**.{cpp,h,mm}

Only manual change in OSVRSession since OSVR headers are not system
headers and they are not standalone / rely on stdint.

Autogenerated with:

cp dom/.clang-format netwerk/ && mach format netwerk/**.{cpp,h,mm}

Manual fixes in:

  • mozurl/cbindgen.toml (including headers earlier)
  • NetlinkService.h (forward-declaring a necessary struct)
  • nsIWebSocketChannel.idl (forward-declaring OriginAttributes).
  • nsAsyncRedirectVerifyHelper.h (forward-declaring nsIEventTarget)

Note that this is probably a bit controversial maybe because of
check_spidermonkey_style changes, see above. I think standardizing on
the same order as the rest of Gecko probably makes sense tho.

Autogenerated with:

cp dom/.clang-format js/ && mach format js/**.{cpp,h,mm}

Manual fixes:

* Make check_spidermonkey_style not check itself for order, since
  the order doesn't match clang-format's.
* Missing include in WasmBCClass-inl.h
Keywords: leave-open

Backed out for causing build bustage
Backout link
Push with failures
Failure log(s)

Flags: needinfo?(emilio)
Flags: needinfo?(emilio)

AssertNoOverflow is defined in that header. This fixes non-unified build
issues locally on windows.

Pushed by pstanciu@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/4408fe95bc97 https://hg.mozilla.org/integration/autoland/rev/c447a83d41c9 Revert "Bug 2054311 - Sort includes in gfx/. r=gfx-reviewers,gw" for causing build bustages @ MockScaledFont.h
Flags: needinfo?(emilio)
Attachment #9606928 - Attachment description: Bug 2054311 - Sort includes in gfx/. r=#gfx-reviewers → Bug 2054311 - Sort includes in gfx/. r=gfx-reviewers,gw
Flags: needinfo?(emilio)
Attachment #9606930 - Attachment description: Bug 2054311 - Sort headers in js/. r=#spidermonkey-reviewers! → Bug 2054311 - Use .clang-format rather than check_spidermonkey_style to sort spidermonkey headers. r=#spidermonkey-reviewers
Pushed by ealvarez@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/2861287f6dc1 https://hg.mozilla.org/integration/autoland/rev/5feb91ff8161 Sort headers in widget/. r=stransky,win-reviewers,geckoview-reviewers,gstoll,owlish
Regressions: 2055018
Blocks: 2055259
Pushed by ealvarez@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/7c43dd397a32 https://hg.mozilla.org/integration/autoland/rev/e832c7354db9 Use .clang-format rather than check_spidermonkey_style to sort spidermonkey headers. r=spidermonkey-reviewers,jandem https://github.com/mozilla-firefox/firefox/commit/934b0109fd73 https://hg.mozilla.org/integration/autoland/rev/2483136b0ecf Reformat js/ after the previous change. r=spidermonkey-reviewers,jandem
Regressions: 2055443
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: