a small implementation for std::expected for C++11
a small implementation for std::expected for C++11

github.com
GitHub - nodeluna/expected: an implementation of std::expected for C++11

a small implementation for std::expected for C++11
GitHub - nodeluna/expected: an implementation of std::expected for C++11
Without a much deep look at the code: any particular reason to not target also C++14?
because "if constexpr(...)" is a c++17 feature which i'm using it to allow usage of nl::unexpected() to return a nl::expected<nl::monostate, E> to nl::expected<T, E> in this copy constructor
but i could take a different approach and make 2 copy constructor one that explicitly takes
and another
I was also using "std::is_same_v" which is a c++17 feature instead "std::is_same<>::value" but i made a commit and changed it. it now compiles with c++14 but with c++17 extensions
That
if constexpr
in the case you mention does make the constructor clean as heck. Thanks for the clarification and the commits, by the way!