capstone.utils.safeunion

A safe union, or variant, disallowing reading invalid types

The C API implements operand values as regular unions, enabling (mis)interpretation of the stored value in any of the encompassed types. This implementation provides a safer union that throws when interpreting the union's value in a different type than it was stored as.

Members

Classes

SafeUnionException
class SafeUnionException

Thrown on misuse of SafeUnion

Templates

SafeUnion
template SafeUnion(U)

Constructs a SafeUnion wrapping the specified union type

Meta