The OpenD Programming Language

equalTo

Predicate that returns a == b. Correctly compares signed and unsigned integers, ie. !(-1 == ~0U).

import std.functional;
alias equalTo = safeOp!"=="

Examples

assert(equalTo(0U, 0));
assert(equalTo(0, 0U));
assert(!equalTo(-1, ~0U));

Meta