[#absl-forward-07] = xref:absl.adoc[absl]::forward :relfileprefix: ../ :mrdocs: `forward` overloads == Synopses Declared in `<absl/utility/utility.h>` Forward an lvalue as either an lvalue or an rvalue. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class T> [[deprecated("Use std::forward instead."), nodiscard]] constexpr T&& xref:absl/forward-0c.adoc[forward](std::remove_reference_t<T>& arg) noexcept; ---- [.small]#xref:absl/forward-0c.adoc[_» more..._]# Forward an rvalue as an rvalue. [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<class T> [[deprecated("Use std::forward instead."), nodiscard]] constexpr T&& xref:absl/forward-0e.adoc[forward](std::remove_reference_t<T>&& arg) noexcept; ---- [.small]#xref:absl/forward-0e.adoc[_» more..._]# [WARNING] ==== https://en.cppreference.com/cpp/language/attributes/deprecated[Deprecated^]: Use std::forward instead.. Use of this entity is allowed but discouraged. ==== == Return Value `arg` cast to the deduced reference type. [NOTE] ==== The return value https://en.cppreference.com/cpp/language/attributes/nodiscard[should not be discarded^]. ==== == Parameters [cols="1,4"] |=== | Name| Description | *arg* | The value to forward. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#