Silenced some weird (very likely false-positive) clang-tidy warnings.
This commit is contained in:
@@ -35,7 +35,7 @@ struct OptionalStorage
|
||||
std::uint8_t used = 0;
|
||||
|
||||
[[nodiscard]]
|
||||
constexpr bool empty() const noexcept { return !used; }
|
||||
constexpr bool empty() const noexcept { return !used; } // NOLINT(clang-analyzer-core.uninitialized.UndefReturn)
|
||||
|
||||
template<typename... TArgs>
|
||||
constexpr void emplace(TArgs&&... args) noexcept
|
||||
@@ -111,7 +111,7 @@ template<typename TValue>
|
||||
class Optional
|
||||
{
|
||||
private:
|
||||
impl::OptionalStorage<TValue> storage_;
|
||||
impl::OptionalStorage<TValue> storage_ = {};
|
||||
public:
|
||||
constexpr Optional() = default;
|
||||
constexpr Optional(NullOptional) noexcept {}
|
||||
|
||||
Reference in New Issue
Block a user