Applied cppcoreguidelines-pro-type-member-init,hicpp-explicit-conversionsm,modernize-use-default-member-init clang-tidy fixes

This commit is contained in:
Bartek Kryza
2022-12-20 22:53:20 +01:00
parent 1116c3ab67
commit 682c6648be
9 changed files with 20 additions and 37 deletions

View File

@@ -31,10 +31,7 @@ template <typename T> class optional_ref {
public:
using optional_type = T;
optional_ref()
: value_{nullptr}
{
}
optional_ref() { }
optional_ref(T *value) { value_ = value; }
@@ -112,7 +109,7 @@ public:
T *get() const { return value_; }
private:
T *value_;
T *value_{nullptr};
};
template <typename T>