Module prelude

Source
Expand description

Prelude extension - available in all contexts, defining common types, operations and constants.

Modules§

generic
Operation to load generic bounded nat parameter.

Structs§

Barrier
A barrier across a row of values. This operation has no effect on the values, except to enforce some ordering between operations before and after the barrier.
BarrierDef
A barrier operation definition.
ConstError
Structure for holding constant error types.
ConstExternalSymbol
A structure for holding references to external symbols.
ConstString
Structure for holding constant string values.
ConstUsize
Structure for holding constant usize values.
MakeTuple
An operation that packs all its inputs into a tuple.
Noop
A no-op operation.
NoopDef
A no-op operation definition.
PRELUDE
Prelude extension, containing common types and operations.
PRELUDE_REGISTRY
An extension registry containing only the prelude
TupleOpDefIter
An iterator over the variants of TupleOpDef
UnpackTuple
An operation that unpacks a tuple into its components.

Enums§

TupleOpDef
Logic extension operation definitions.

Constants§

BARRIER_OP_ID
Name of the barrier operation.
DEFAULT_ERROR_SIGNAL
Default error signal.
ERROR_TYPE_NAME
The string name of the error type.
EXIT_OP_ID
Name of the prelude exit operation.
MAKE_ERROR_OP_ID
Name of the prelude MakeError operation.
NOOP_OP_ID
Name of the no-op operation.
PANIC_OP_ID
Name of the prelude panic operation.
PRELUDE_ID
Name of prelude extension.
PRINT_OP_ID
Name of the print operation
STRING_TYPE_NAME
Name of the string type.
VERSION
Extension version.

Traits§

UnwrapBuilder
Extend dataflow builders with methods for building unwrap operations.

Functions§

bool_t
Boolean type - Sum of two units.
const_fail
A constant Either value with a failure variant.
const_fail_tuple
A constant Either with a row of failure values.
const_left
A constant Either value with a left variant.
const_left_tuple
A constant Either value with a row of left values.
const_none
A constant optional value with no value.
const_ok
A constant Either value with a success variant.
const_ok_tuple
A constant Either with a row of success values.
const_right
A constant Either value with a right variant.
const_right_tuple
A constant Either value with a row of right values.
const_some
A constant optional value with a given value.
const_some_tuple
A constant optional value with a row of values.
either_type
An “either” type, i.e. a Sum type with a “left” and a “right” variant.
error_type
Unspecified opaque error type.
option_type
An optional type, i.e. a Sum type with the second variant as the given type and the first as an empty tuple.
qb_t
Qubit type.
string_type
String type.
sum_with_error
Return a Sum type with the second variant as the given type and the first an Error.
usize_t
Unsigned size type.