Vector.opBinaryRight

Returns a new vector of greater dimension by copying elements and prepending values from other.

  1. Vector opBinaryRight(T scalar)
  2. auto opBinaryRight(U scalar)
  3. Vector!(CommonType!(U, T), max(N, M)) opBinaryRight(U[M] other)
  4. Vector!(T, N + 1) opBinaryRight(T scalar)
  5. Vector!(T, N + M) opBinaryRight(T[M] other)
    struct Vector(T, uint N)
    pure const
    Vector!(T, N + M)
    opBinaryRight
    (
    string op : "~"
    uint M
    )
    (
    const auto ref T[M] other
    )
    if (
    N > 0
    )

Examples

Vec2 v1 = [1, 2];
assert([3f, 4f] ~ v1 == Vec4(3, 4, 1, 2));
assert(Vec2(3f, 4f) ~ v1 == Vec4(3, 4, 1, 2));

Meta