rValue

Allows to pass always a parameter as value even if it would be accepted as reference.

rValue
(
T
)
(
auto ref T t
)

Examples

void foo(T)(ref T t){}
uint a;
static assert(is(typeof(foo(a))));
static assert(!is(typeof(foo(a.rValue))));

Meta