Page MenuHomeFreeBSD

Set AlignTrailingComments in the clang-format config
ClosedPublic

Authored by arichardson on Thu, Sep 10, 1:38 PM.

Details

Summary

This seems to be fairly common in existing code and often looks better when
adding trailing comments to e.g. enumerators or array initializers.
See D26340 for more context.

Diff Detail

Repository
rS FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

arichardson requested review of this revision.Thu, Sep 10, 1:38 PM
arichardson created this revision.

correct diff

emaste accepted this revision.Thu, Sep 10, 1:56 PM

I'm curious how well this works in practice (i.e., it's often difficult to simultaneously address aligned comments and line length limits) but this is probably the right choice.

This revision is now accepted and ready to land.Thu, Sep 10, 1:56 PM
This revision was automatically updated to reflect the committed changes.