predicates

Predicate extensions to std.algorithm.

Members

Aliases

isEither
alias isEither = of
Undocumented in source.
isInited
alias isInited = isDefaulted
Undocumented in source.
isUntouched
alias isUntouched = isDefaulted
Undocumented in source.
zeroed
alias zeroed = allZero
Undocumented in source.

Functions

allEqual
bool allEqual(R range)
allEqualTo
bool allEqualTo(R range, E element)
allZero
bool allZero(T x)

Check if all Elements of x are zero.

isDefaulted
bool isDefaulted(T a)
isPowerOf2
bool isPowerOf2(uint x)

Check if x is a power of 2 (binary power). See also: http://forum.dlang.org/thread/zumhmosfkvwjymjhmtlt@forum.dlang.org#post-fvnmurrctavpfkunssdf:40forum.dlang.org

of
bool of(S x, T ys)

Return true if x is a equal to any of ys. TODO Make ys lazy if any of ys is a delegate. TODO Reuse among

of
bool of(E x, R ys)

Return true if x is a equal to any of ys. TODO Reuse among

Meta