The OpenD Programming Language

castTo

Construct a shared pointer of a required type with a current context. Provides polymorphism abilities for classes and structures with alias this syntax.

  1. mir_rcptr!R castTo(mir_rcptr!T context)
  2. mir_rcptr!(const R) castTo(mir_rcptr!T context)
  3. mir_rcptr!(immutable R) castTo(mir_rcptr!T context)
    @trusted
    mir_rcptr!(immutable R)
    castTo
    (
    R
    T
    )
    (
    return immutable mir_rcptr!T context
    )
    if (
    isImplicitlyConvertible!(immutable T, immutable R)
    )

Meta