Add explicit member initialization to mitigate -Werror=effc++
This commit is contained in:
parent
7510f32ff7
commit
1bef04620a
@ -86,7 +86,10 @@ class optional
|
|||||||
return std::move(base_value);
|
return std::move(base_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
constexpr optional() noexcept(noexcept(std::optional<noexcept_fix_t>())) = default;
|
constexpr optional() noexcept(noexcept(std::optional<noexcept_fix_t>()))
|
||||||
|
: base_value() // explicitly initialized to mitigate -Werror=effc++
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
constexpr optional(std::nullopt_t /* unused */) noexcept
|
constexpr optional(std::nullopt_t /* unused */) noexcept
|
||||||
: base_value(std::nullopt)
|
: base_value(std::nullopt)
|
||||||
|
|||||||
@ -4678,7 +4678,10 @@ class optional
|
|||||||
return std::move(base_value);
|
return std::move(base_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
constexpr optional() noexcept(noexcept(std::optional<noexcept_fix_t>())) = default;
|
constexpr optional() noexcept(noexcept(std::optional<noexcept_fix_t>()))
|
||||||
|
: base_value() // explicitly initialized to mitigate -Werror=effc++
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
constexpr optional(std::nullopt_t /* unused */) noexcept
|
constexpr optional(std::nullopt_t /* unused */) noexcept
|
||||||
: base_value(std::nullopt)
|
: base_value(std::nullopt)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user