Page MenuHomePhabricator

[clang-format] Add SpaceInEmptyBlock option for WebKit
ClosedPublic

Authored by owenpan on Aug 7 2019, 11:45 PM.

Diff Detail

Repository
rL LLVM

Event Timeline

owenpan created this revision.Aug 7 2019, 11:45 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 7 2019, 11:45 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
lebedev.ri retitled this revision from Add SpaceInEmptyBlock option for WebKit to [clang-format] Add SpaceInEmptyBlock option for WebKit.Aug 7 2019, 11:54 PM
sammccall accepted this revision.Aug 9 2019, 3:12 PM
sammccall added inline comments.
clang/docs/ClangFormatStyleOptions.rst
2120 ↗(On Diff #214069)

may -> will?

clang/include/clang/Format/Format.h
1802 ↗(On Diff #214069)

(and here)

This revision is now accepted and ready to land.Aug 9 2019, 3:12 PM

https://webkit.org/code-style-guidelines/ has one instance of { } with a space and one of {} without a space, and as far as I can tell no text that says which instance is correct. Are you sure this is the right thing for webkit style?

owenpan marked 2 inline comments as done.Aug 10 2019, 12:32 AM
owenpan updated this revision to Diff 214509.Aug 10 2019, 12:39 AM

Changed "may" to "will" and updated the diff. (Should we do the same for the SpaceInEmptyParentheses option?)

https://webkit.org/code-style-guidelines/ has one instance of { } with a space and one of {} without a space, and as far as I can tell no text that says which instance is correct. Are you sure this is the right thing for webkit style?

The one without a space is an example of "Wrong" WebKit style there.

This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptAug 10 2019, 12:52 AM