Skip to content

Commit b924f4a

Browse files
committed
Implement missing nothrow constructor for errored_status_code.
1 parent 2e24b8f commit b924f4a

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

include/status-code/errored_status_code.hpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,13 @@ class errored_status_code<detail::erased<ErasedType>> : public status_code<detai
296296
_check();
297297
}
298298
#endif
299+
//! Tagged copy construction from an unknown status code. Note that this will be empty if its value type is not
300+
//! trivially copyable or would not fit into our storage or the source domain's `_do_erased_copy()` refused the copy.
301+
SYSTEM_ERROR2_CONSTEXPR20 errored_status_code(std::nothrow_t _, const status_code<void> &v) noexcept // NOLINT
302+
: _base(_, v)
303+
{
304+
_check();
305+
}
299306

300307
//! Always false (including at compile time), as errored status codes are never successful.
301308
constexpr bool success() const noexcept { return false; }

0 commit comments

Comments
 (0)