[#BloombergLP-bslmf-MovableRefUtil-move_if_noexcept-0e] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslmf.adoc[bslmf]::xref:BloombergLP/bslmf/MovableRefUtil.adoc[MovableRefUtil]::move_if_noexcept :relfileprefix: ../../../ :mrdocs: `move_if_noexcept` overloads == Synopses Declared in `<bslmf_movableref.h>` Return a const‐qualified reference to the specified `lvalue`. This function is selected by overload resolution if the move constructor for `t_TYPE` might throw an exception. Constructing a `t_TYPE` object from the result will result in the copy constructor being invoked rather than the (unsafe) move constructor. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class t_TYPE> static t_TYPE const& xref:BloombergLP/bslmf/MovableRefUtil/move_if_noexcept-04.adoc[move_if_noexcept](t_TYPE& lvalue) noexcept requires !bsl::is_nothrow_move_constructible<t_TYPE>::value && bsl::is_copy_constructible<t_TYPE>::value; ---- [.small]#xref:BloombergLP/bslmf/MovableRefUtil/move_if_noexcept-04.adoc[_» more..._]# Return a movable reference to the specified `lvalue`. This function is selected by overload resolution if the move constructor for `t_TYPE` is nothrow‐move‐constructible. Constructing a `t_TYPE` object from the result will result in the (safe) move constructor being invoked. Note that that the `bsl::is_nothrow_move_constructible` trait can be customized in C++03 mode to indicate that a type is nothrow‐move‐constructible. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class t_TYPE> static xref:BloombergLP/bslmf/MovableRef.adoc[MovableRef<t_TYPE>] xref:BloombergLP/bslmf/MovableRefUtil/move_if_noexcept-00.adoc[move_if_noexcept](t_TYPE& lvalue) noexcept requires !bsl::is_copy_constructible<t_TYPE>::value || bsl::is_nothrow_move_constructible<t_TYPE>::value; ---- [.small]#xref:BloombergLP/bslmf/MovableRefUtil/move_if_noexcept-00.adoc[_» more..._]# [.small]#Created with https://www.mrdocs.com[MrDocs]#