diff --git a/source/mijin/container/optional.hpp b/source/mijin/container/optional.hpp index 54ae8ed..57b2ac4 100644 --- a/source/mijin/container/optional.hpp +++ b/source/mijin/container/optional.hpp @@ -142,6 +142,10 @@ public: constexpr std::remove_reference_t& operator*() noexcept { return get(); } [[nodiscard]] constexpr const std::remove_reference_t& operator*() const noexcept { return get(); } + [[nodiscard]] + constexpr std::remove_reference_t* operator->() noexcept { return &get(); } + [[nodiscard]] + constexpr const std::remove_reference_t* operator->() const noexcept { return &get(); } public: template void emplace(Types&&... params) noexcept;