core.internal.dassert

Functions 1

fnstring _d_assert_fail(A)(const scope string op, auto ref const scope A a)Generates rich assert error messages for unary expressions

Templates 2

tmpl_d_assert_fail(A...)

Generates rich assert error messages for binary expressions

The binary expression assert(x == y) will be turned into assert(x == y, _d_assert_fail!(typeof(x))("==", x, y)).

Parameters

compComparison operator that was used in the expression.
aLeft hand side operand (can be a tuple).
bRight hand side operand (can be a tuple).

Returns

A string such as "$a $comp $b".
Functions
string _d_assert_fail(B...)( const scope string comp, auto ref const scope A a, auto ref const scope B b) if (B.length != 0 || A.length != 1)
tmplgetPrintfFormat(T)

Yields the appropriate printf format token for a type T