From c8b73031d8a9f7770410c9d0e6da5b230e501e85 Mon Sep 17 00:00:00 2001 From: Steven Le Rouzic Date: Wed, 12 Mar 2025 00:08:18 +0100 Subject: Remove convertible_from --- asl/types/option.hpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'asl/types/option.hpp') diff --git a/asl/types/option.hpp b/asl/types/option.hpp index 9c317b0..982c63d 100644 --- a/asl/types/option.hpp +++ b/asl/types/option.hpp @@ -110,7 +110,7 @@ public: constexpr option(nullopt_t) requires kHasNiche : m_payload{in_place, niche_t{}} {} template - constexpr explicit (!convertible_from) + constexpr explicit (!convertible_to) option(U&& value) requires ( kHasNiche && @@ -121,7 +121,7 @@ public: {} template - constexpr explicit (!convertible_from) + constexpr explicit (!convertible_to) option(U&& value) requires ( !kHasNiche && @@ -159,7 +159,7 @@ public: } template - constexpr explicit (!convertible_from) + constexpr explicit (!convertible_to) option(const option& other) requires ( constructible_from && @@ -174,7 +174,7 @@ public: } template - constexpr explicit (!convertible_from) + constexpr explicit (!convertible_to) option(option&& other) requires ( constructible_from && @@ -377,14 +377,14 @@ public: template constexpr T value_or(U&& other_value) const& - requires copy_constructible && convertible_from + requires copy_constructible && convertible_to { return has_value() ? value() : static_cast(std::forward(other_value)); } template constexpr T value_or(U&& other_value) && - requires move_constructible && convertible_from + requires move_constructible && convertible_to { return has_value() ? std::move(value()) : static_cast(std::forward(other_value)); } -- cgit