Function isConditional

Check if the opcode is a conditional

bool isConditional (
  in const(OP) opcode
) pure nothrow @nogc @safe;

Parameters

NameDescription
opcode opcode to check

Returns

true if the opcode is one of the conditional opcodes

Example

assert(OP.IF.isConditional);
assert(OP.NOT_IF.isConditional);
assert(OP.ELSE.isConditional);
assert(OP.END_IF.isConditional);
assert(!OP.TRUE.isConditional);
assert(!OP.HASH.isConditional);