SmartInt.opCmp

Perform a mathematically correct comparison to right.

  1. auto opCmp(M right)
  2. int opCmp(M right)
    struct SmartInt(N, IntFlagPolicy _policy, Flag!"bitOps" bitOps = Yes.bitOps)
    const pure nothrow @nogc
    int
    opCmp
    (
    M
    )
    (
    const M right
    )
    if (
    isScalarType!M
    )
    if (
    isIntegral!N &&
    )

Return Value

Type: int
  • -1 if this value is less than right.
  • 0 if this value is precisely equal to right.
  • 1 if this value is greater than right.
  • float.nan if right is a floating-point nan value.

Meta