[cfe-dev] clang-format: ShortFunctionsOnASingleLine

Daniel Jasper via cfe-dev cfe-dev at lists.llvm.org
Thu Oct 15 06:30:21 PDT 2015


Seems like that option doesn't properly work together with the brace style
you have selected. Feel free to file a bug.

On Thu, Oct 15, 2015 at 6:14 AM, Florian Lindner via cfe-dev <
cfe-dev at lists.llvm.org> wrote:

> Hello,
>
> I have this piece of code:
>
> class C
> {
>   C() {}
> };
>
> void f() {}
>
> AllowShortFunctionsOnASingleLine is set to empty, so I expect these
> function to be left as is.
>
> florian at asaru ~/scratch (git)-[master] % clang-format -style=file
> -dump-config | grep ShortFunction
> AllowShortFunctionsOnASingleLine: Empty
>
> However:
>
> florian at asaru ~/scratch (git)-[master] % clang-format -style=file
> clangformat.cpp
> class C
> {
>   C()
>   {
>   }
> };
>
> void f()
> {
> }
>
>
> Is there something I misunderstand about this option?
>
> Thanks,
> Florian
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20151015/fb6a7143/attachment.html>


More information about the cfe-dev mailing list