[PATCH] D104044: [clang-format] Fix the issue that empty lines being removed at the beginning of namespace

Darwin Xu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 28 05:49:47 PDT 2021


darwin marked an inline comment as done.
darwin added inline comments.


================
Comment at: clang/lib/Format/UnwrappedLineFormatter.cpp:1270
       !startsExternCBlock(*PreviousLine))
     Newlines = 1;
 
----------------
MyDeveloperDay wrote:
> Nit:I do think at some point we need to have some sort of option for controlling these empty lines, 
> 
> ````
> EmptyLine:
>          AfterNamespace: 1
>          BeforeAccessModifier: 1
>          AfterAccessModifier: 1
>          BetweenFunctions: 1
>          ...
> ````
Yes, maybe we can open a bug for it.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D104044



More information about the cfe-commits mailing list