operator - method

Pointer<T> operator -(
  1. int offset
)

A pointer to the offsetth T before this one.

Equivalent to this + (-offset).

Returns a pointer to the T whose address is offset times the size of T before the address of this pointer. That is, (this - offset).address == this.address - offset * sizeOf<T>().

Also, (this - offset).value is equivalent to this[-offset], and similarly for setting,

Implementation

external Pointer<T> operator -(int offset);