From: Simon Marchi Date: Mon, 16 Sep 2024 09:00:35 +0000 (-0400) Subject: Bump required clang-format version to 16 X-Git-Url: http://git.lttng.org./?a=commitdiff_plain;h=b180de7857beb0717b2fa9b1d5399ac004d921b5;p=lttng-tools.git Bump required clang-format version to 16 Bump the required clang-format version from 14 to 16. For reference, this is the version the Babeltrace project uses [1], and it is checked by the LTTng CI [2], so I think it makes sense to go to that version. More recent versions might not be readily available on the CI machines (mostly running Debian 12 at the moment). FWIW, I think that the code changes generated by this version change are improvements. [1] https://github.com/efficios/babeltrace/blob/d16ccfd174984c3d18f4f4427e4e438b1a64730e/tools/format-cpp.sh#L7 [2] https://ci.lttng.org/view/Babeltrace/job/babeltrace_master_lint/ Change-Id: I188f04928357ac7562b1a2dce3238a622189b04a Signed-off-by: Simon Marchi Signed-off-by: Jérémie Galarneau --- diff --git a/format-cpp b/format-cpp index a3943ae57..7bc26d1f3 100755 --- a/format-cpp +++ b/format-cpp @@ -4,7 +4,7 @@ # # Copyright (C) 2020-2022 Philippe Proulx -expected_formatter_major_version=14 +expected_formatter_major_version=16 SCRIPT_DIR=$(dirname "$0")/ diff --git a/src/common/scope-exit.hpp b/src/common/scope-exit.hpp index 3f8c90f80..f8225754a 100644 --- a/src/common/scope-exit.hpp +++ b/src/common/scope-exit.hpp @@ -16,8 +16,7 @@ namespace details { /* Is operator() of InvocableType is marked as noexcept? */ template struct is_invocation_noexcept - : std::integral_constant())())> { -}; + : std::integral_constant())())> {}; } /* namespace details. */ /* diff --git a/src/common/type-traits.hpp b/src/common/type-traits.hpp index 3801bf13f..1783a5302 100644 --- a/src/common/type-traits.hpp +++ b/src/common/type-traits.hpp @@ -22,16 +22,13 @@ namespace traits { * `false` */ template -struct is_one_of : std::false_type { -}; +struct is_one_of : std::false_type {}; template -struct is_one_of : std::true_type { -}; +struct is_one_of : std::true_type {}; template -struct is_one_of : is_one_of { -}; +struct is_one_of : is_one_of {}; } /* namespace traits */ } /* namespace lttng */