Navigation
API > API/Runtime > API/Runtime/Core
Description
ForwardLike will cast a reference to an object with the cv qualifiers and value category of another type. This allows perfect forwarding of subobjects with the same cvrefs as the outer type. Qualifiers and refs from each type are composed, so const will never be cast away, nor will an lvalue be cast to an rvalue.
Example:
template
| Name | ForwardLike |
| Type | function |
| Header File | /Engine/Source/Runtime/Core/Public/Templates/UnrealTemplate.h |
| Include Path | #include "Templates/UnrealTemplate.h" |
template<typename T, typename U>
decltype(auto) ForwardLike
(
U && Obj
)