[PATCH] D92257: [clang-format] Add option to control the space at the front of a line comment

Björn Schäpers via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jan 29 13:06:31 PST 2021


HazardyKnusperkeks updated this revision to Diff 320196.
HazardyKnusperkeks added a comment.

The previous one broke a (format) test in polly. This lead me to change the one breaking behavior, no it is not breaking anymore.
A comment starting with `}` will only be indented if it is in a comment section which will get an indention. Test case is adapted.

I will wait a few days if there is no negative feedback I will push it again.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D92257/new/

https://reviews.llvm.org/D92257

Files:
  clang/docs/ClangFormatStyleOptions.rst
  clang/docs/ReleaseNotes.rst
  clang/include/clang/Format/Format.h
  clang/lib/Format/BreakableToken.cpp
  clang/lib/Format/BreakableToken.h
  clang/lib/Format/Format.cpp
  clang/lib/Format/NamespaceEndCommentsFixer.cpp
  clang/unittests/Format/FormatTest.cpp
  clang/unittests/Format/FormatTestComments.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D92257.320196.patch
Type: text/x-patch
Size: 35890 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210129/1d0cde49/attachment-0001.bin>


More information about the cfe-commits mailing list