[PATCH] D132131: [clang-format] Adds a formatter for aligning trailing comments over empty lines

MyDeveloperDay via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 5 03:47:59 PDT 2022


MyDeveloperDay added a comment.

I feel this patch leave the documentation in a right state, I won’t be giving it an accept in this form. Please also mark the comments as done once addressed so we know you’ve read and fixed our requests



================
Comment at: clang/docs/ClangFormatStyleOptions.rst:823
+
+  * ``bool AcrossEmptyLines`` Whether to align across empty lines.
+
----------------
I’m sorry I just don’t think this documentation is now correct, all because you are trying I believe to reuse a structure that has options that’s not needed,


================
Comment at: clang/include/clang/Format/Format.h:298
+  /// Style of aligning consecutive trailing comments.
+  /// This option existed as ``AlignTrailingComments`` since version 3.7.
+  ///
----------------
Isn’t this completely wrong?


================
Comment at: clang/include/clang/Format/Format.h:384
 
-  /// If ``true``, aligns trailing comments.
-  /// \code
-  ///   true:                                   false:
-  ///   int a;     // My comment a      vs.     int a; // My comment a
-  ///   int b = 2; // comment  b                int b = 2; // comment about b
-  /// \endcode
+  /// This option is **deprecated**. See ``AlignConsecutiveTrailingComments``.
   /// \version 3.7
----------------
And this


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132131



More information about the cfe-commits mailing list