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

MyDeveloperDay via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Jun 27 06:42:09 PDT 2021


MyDeveloperDay added inline comments.


================
Comment at: clang/lib/Format/UnwrappedLineFormatter.cpp:1270
       !startsExternCBlock(*PreviousLine))
     Newlines = 1;
 
----------------
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
         ...
````


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

https://reviews.llvm.org/D104044



More information about the cfe-commits mailing list