Skip to content

Commit aeb9231

Browse files
committed
⚠️ Fix "suggest braces around initialization of subobject" warnings
Warnings are visible as errors with compiler ``` g++ --version Apple clang version 16.0.0 (clang-1600.0.26.4) Target: arm64-apple-darwin24.1.0 Thread model: posix InstalledDir: /Library/Developer/CommandLineTools/usr/bin ```
1 parent fb3cc27 commit aeb9231

File tree

7 files changed

+7
-7
lines changed

7 files changed

+7
-7
lines changed

include/cib/detail/config_details.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ template <typename... ConfigTs> struct config : public detail::config_item {
1717
stdx::tuple<ConfigTs...> configs_tuple;
1818

1919
CONSTEVAL explicit config(ConfigTs const &...configs)
20-
: configs_tuple{configs...} {}
20+
: configs_tuple{{{configs}...}} {}
2121

2222
[[nodiscard]] constexpr auto extends_tuple() const {
2323
return configs_tuple.apply([&](auto const &...configs_pack) {

include/cib/detail/exports.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ template <typename ServiceT, typename BuilderT> struct service_entry {
1414
template <typename... Services> struct exports : public detail::config_item {
1515
[[nodiscard]] constexpr auto
1616
extends_tuple() const -> stdx::tuple<extend<Services>...> {
17-
return {extend<Services>{}...};
17+
return {{{extend<Services>{}}...}};
1818
}
1919

2020
[[nodiscard]] constexpr auto

include/cib/detail/extend.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ struct extend : public config_item {
1313
constexpr static auto builder = cib::builder_t<service_type>{};
1414
stdx::tuple<Args...> args_tuple;
1515

16-
CONSTEVAL explicit extend(Args const &...args) : args_tuple{args...} {}
16+
CONSTEVAL explicit extend(Args const &...args) : args_tuple{{{args}...}} {}
1717

1818
[[nodiscard]] constexpr auto extends_tuple() const -> stdx::tuple<extend> {
1919
return {*this};

include/flow/graph_builder.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ class graph {
281281
return fragments.apply([&](auto &...frags) {
282282
return graph<Name, Renderer, Fragments...,
283283
stdx::remove_cvref_t<Ns>...>{
284-
{frags..., std::forward<Ns>(ns)...}};
284+
{{{frags}..., {std::forward<Ns>(ns)}...}}};
285285
});
286286
}
287287

include/log/catalog/mipi_encoder.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ template <typename TDestinations> struct log_handler {
224224
template <typename... TDestinations> struct config {
225225
using destinations_tuple_t = stdx::tuple<TDestinations...>;
226226
constexpr explicit config(TDestinations... dests)
227-
: logger{stdx::tuple{std::move(dests)...}} {}
227+
: logger{stdx::make_tuple(std::move(dests)...)} {}
228228

229229
log_handler<destinations_tuple_t> logger;
230230
};

include/msg/message.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ template <stdx::ct_string Name, typename... Fields> class message_access {
265265
decltype(stdx::ct_string_to_type<Name, sc::string_constant>());
266266
auto const descs = [&] {
267267
auto const field_descriptions =
268-
stdx::tuple{Fields::describe(Fields::extract(r))...};
268+
stdx::make_tuple(Fields::describe(Fields::extract(r))...);
269269
if constexpr (sizeof...(Fields) > 0) {
270270
return field_descriptions.join(
271271
[](auto lhs, auto rhs) { return lhs + ", "_sc + rhs; });

test/interrupt/shared_sub_irq_impl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ TEST_CASE(
9999
interrupt::shared_sub_irq_impl<flow_config_t<std::true_type>,
100100
active_sub_impl_t, inactive_sub_impl_t>;
101101

102-
auto expected = stdx::tuple{enable_field_t<0>{}, enable_field_t<17>{}};
102+
auto expected = stdx::make_tuple(enable_field_t<0>{}, enable_field_t<17>{});
103103
auto actual = impl_t::get_interrupt_enables();
104104

105105
CHECK(std::size(expected) == std::size(actual));

0 commit comments

Comments
 (0)