this < rhs
- Zero if
this == rhs - Positive value if
this > rhs
int opCmp(const var rhs) const @safeThree-way comparison operator for var.
Enables use of `<`, `<=`, `>`, `>=` operators between var values.
Comparison rules:
If either operand is floating-point, both are compared as double. Otherwise, integers are compared without wrap-around:
ulong.long.always less than any unsigned value).
false < true.NULL is considered less than any non-NULL value.Two NULL values are equal (returns 0).
Shorter arrays are less than longer arrays if all elements match.
or both empty, otherwise comparison is undefined (returns 0).
(e.g., string vs array), the result is based on type tag ordering.
this < rhs
this == rhsthis > rhs