The OpenD Programming Language

castFrom.to

template castFrom(From)
ref @system
to
(
To
T
)
(
auto ref T value
)

Parameters

To

The type to cast to.

value T

The value to cast. It must be of type From, otherwise a compile-time error is emitted.

Return Value

Type: auto ref

the value after the cast, returned by reference if possible.

Meta