Abort.hookOpEquals

bool hookOpEquals(Lhs, Rhs)(Lhs lhs, Rhs rhs)

Called automatically upon a comparison for equality. In case of a erroneous comparison (one that would make a signed negative value appear equal to an unsigned positive value), this hook issues assert(0) which terminates the application.

Parameters

lhsThe first argument of Checked, e.g. int if the left-hand side of the operator is Checked!int
rhsThe right-hand side type involved in the operator

Returns

Upon a correct comparison, returns the result of the comparison.

Otherwise, the function terminates the application so it never returns.