clang-format: copy latest and re-format
clang-format-16 has some backwards incompatible changes that require
additional settings for best compatibility and re-running the formatter.
Copy the latest .clang-format from the docs repository and reformat the
repository.
Change-Id: I152f141a5e8343b92b5ce81d3ca16eec77b5606b
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/control/json/actions/mapped_floor.cpp b/control/json/actions/mapped_floor.cpp
index 906559b..c947098 100644
--- a/control/json/actions/mapped_floor.cpp
+++ b/control/json/actions/mapped_floor.cpp
@@ -158,7 +158,6 @@
if (!floorEntry.contains("value") ||
!floorEntry.contains("floor"))
{
-
throw ActionParseError{
ActionBase::getName(),
"Missing value or floor entries in "
@@ -234,12 +233,11 @@
{
std::visit(
[&value](auto&& val) {
- using V = std::decay_t<decltype(val)>;
- if constexpr (std::is_same_v<int32_t, V> ||
- std::is_same_v<int64_t, V>)
- {
- value = static_cast<double>(val);
- }
+ using V = std::decay_t<decltype(val)>;
+ if constexpr (std::is_same_v<int32_t, V> || std::is_same_v<int64_t, V>)
+ {
+ value = static_cast<double>(val);
+ }
},
value);
}
@@ -264,16 +262,16 @@
{
std::visit(
[&group, this](auto&& val) {
- using V = std::decay_t<decltype(val)>;
- if constexpr (!std::is_same_v<double, V> &&
- !std::is_same_v<int32_t, V> &&
- !std::is_same_v<int64_t, V>)
- {
- throw std::runtime_error{fmt::format(
- "{}: Group {} has more than one member but "
- "isn't numeric",
- ActionBase::getName(), group.getName())};
- }
+ using V = std::decay_t<decltype(val)>;
+ if constexpr (!std::is_same_v<double, V> &&
+ !std::is_same_v<int32_t, V> &&
+ !std::is_same_v<int64_t, V>)
+ {
+ throw std::runtime_error{fmt::format(
+ "{}: Group {} has more than one member but "
+ "isn't numeric",
+ ActionBase::getName(), group.getName())};
+ }
},
value);
checked = true;