Getting clang-format to format requires-expression on one line

Viewed 82

Here is my code:

if constexpr (requires { { N::uuid() } -> std::convertible_to<score::uuid_t>; })

clang-format (14, 15) insists in formatting it in 5 lines:

if constexpr (requires {
                {
                  N::uuid()
                  } -> std::convertible_to<score::uuid_t>;
              })

which is insane, how can I ensure that it stays on one line without having to annotate every single line ?

0 Answers
Related