[cfe-dev] clang-format closing brackets

Han Wang via cfe-dev cfe-dev at lists.llvm.org
Tue Jul 12 01:07:57 PDT 2016


Hi,

Let's say I have some big multi-line function call or multi-line template
argument list.

Foo(
  param1,
  param2,
  param3,
  param4
);

template <
  typename T,
  std::enable_if_t<
    ...
  >* = nullptr
>

I want the closing brackets to be at the same indentation level with their
opening counterparts. But clang-format always put the closing brackets to
the end of the last parameter/argument. Is there a way to solve this?
Thanks.

Foo(
  param1,
  param2,
  param3,
  param4); // how to move ); to next line

template <
  typename T,
  std::enable_if_t<
    ...>* = nullptr> // how to move >* = nullptr and > to next lines

Best regards,
Han
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20160712/13e0e256/attachment.html>


More information about the cfe-dev mailing list