https://llvm.org/bugs/show_bug.cgi?id=28614

            Bug ID: 28614
           Summary: Inconsistent formatting of functions with anonymous
                    parameters
           Product: clang
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Formatter
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected]
    Classification: Unclassified

I think the example says it all.

$ clang-format -style='{BreakBeforeBraces: Allman, AlwaysBreakAfterReturnType:
All}' <<EOF
> class C
> {
>     void f() {}
>     void f(int) {}
>     void f(a::b) {}
>     void f(a::b c) {}
> };
> EOF
class C
{
  void
  f()
  {
  }
  void
  f(int)
  {
  }
  void f(a::b) {}
  void
  f(a::b c)
  {
  }
};


Note that the function void f(a::b) is not formatted like the others. Also note
that this does not happen when the function is not in a class.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to