isRvalueAssignable

Returns true iff an rvalue of type Rhs can be assigned to a variable of type Lhs.

enum isRvalueAssignable (
Lhs
Rhs = Lhs
)

Examples

struct S1
{
    void opAssign(S1);
}

struct S2
{
    void opAssign(ref S2);
}

static assert( isRvalueAssignable!(long, int));
static assert(!isRvalueAssignable!(int, long));
static assert( isRvalueAssignable!S1);
static assert(!isRvalueAssignable!S2);

Meta