Author: Passw Date: 2022-09-06T12:24:18+02:00 New Revision: 2adf241592b38189994c6c9d2dfbfa391ecbe9fa
URL: https://github.com/llvm/llvm-project/commit/2adf241592b38189994c6c9d2dfbfa391ecbe9fa DIFF: https://github.com/llvm/llvm-project/commit/2adf241592b38189994c6c9d2dfbfa391ecbe9fa.diff LOG: [clang-format] [doc] Fix example of wrapping class definitions Example of BraceWrapping AfterClass is wrong Differential Revision: https://reviews.llvm.org/D133087 Added: Modified: clang/docs/ClangFormatStyleOptions.rst clang/include/clang/Format/Format.h Removed: ################################################################################ diff --git a/clang/docs/ClangFormatStyleOptions.rst b/clang/docs/ClangFormatStyleOptions.rst index 8bc24c81c9ec2..01ebbd72aae44 100644 --- a/clang/docs/ClangFormatStyleOptions.rst +++ b/clang/docs/ClangFormatStyleOptions.rst @@ -1439,12 +1439,12 @@ the configuration (without a prefix: ``Auto``). .. code-block:: c++ true: - class foo {}; - - false: class foo {}; + false: + class foo {}; + * ``BraceWrappingAfterControlStatementStyle AfterControlStatement`` Wrap control statements (``if``/``for``/``while``/``switch``/..). diff --git a/clang/include/clang/Format/Format.h b/clang/include/clang/Format/Format.h index e057632cc1b02..c1e2fd54cd67d 100644 --- a/clang/include/clang/Format/Format.h +++ b/clang/include/clang/Format/Format.h @@ -1423,11 +1423,11 @@ struct FormatStyle { /// Wrap class definitions. /// \code /// true: - /// class foo {}; - /// - /// false: /// class foo /// {}; + /// + /// false: + /// class foo {}; /// \endcode bool AfterClass; _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits