Crate snarkvm_compiler
source · [−]Modules
Macros
This macro executes the given block of operations as a new atomic write batch IFF there is no atomic write batch in progress yet. This ensures that complex atomic operations consisting of multiple lower-level operations - which might also need to be atomic if executed individually - are executed as a single large atomic operation regardless.
A helper macro to downcast a $variable
to $object<$network>
.
Creates a match statement that evaluates the operation.
Creates a match statement that executes the operation.
Creates a match statement that applies the given operation for each instruction.
Creates a new struct
that implements the Operation
trait.
Creates a match statement that returns the output type given the input types.
A helper macro to dedup the Network
trait and Aleo
trait and process its given logic.
A helper macro to dedup the Network
trait and Aleo
trait and process its given logic.
Structs
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
Asserts an operation on two operands.
An in-memory block storage.
The block store.
Calls the operands into the declared type.
i.e. call transfer r0.owner 0u64 r1.amount into r1 r2;
Casts the operands into the declared type.
Commits the operand into the declared type.
An in-memory deployment storage.
The deployment store.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
An in-memory execution storage.
The execution store.
The implementation of the binary operation.
The implementation of the binary operation.
Hashes the operand into the declared type.
The header for the block contains metadata that uniquely identifies the block.
The Merkle leaf for the block header.
An import statement defines an imported program, and is of the form import {name}.{network};
.
If no network
-level domain is specified, the default network is used.
An in-memory transition input storage.
The transition input store.
The implementation of the binary operation.
Computes an equality operation on two operands, and stored the outcome in destination
.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
An in-memory transition output storage.
The transition output store.
The implementation of the binary operation.
The implementation of the binary operation.
An in-memory program state storage.
The program store.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The implementation of the binary operation.
The Merkle leaf for a function or transition in the transaction.
An in-memory transaction storage.
The transaction store.
The Merkle leaf for an input or output ID in the transition.
An in-memory transition storage.
The transition store.
The implementation of the binary operation.
Enums
The operator references a function name or closure name.
The transition input.
The Opcode
enum stores the mnemonic for the instruction.
The Operand
enum represents the options for an operand in an instruction.
This enum is designed to for instructions such as add {Register} {Literal} into {Register}
.
The transition output.
Traits
A trait for block storage.
A trait for deployment storage.
A trait for execution storage.
A trait for transition input storage.
A trait representing map-like storage operations with read-write capabilities.
A trait representing map-like storage operations with read-only capabilities.
A trait for transition output storage.
A trait for program state storage. Note: For the program logic, see DeploymentStorage
.
A trait for transaction storage.
A trait for transition storage.
Type Definitions
Compute the absolute value of first
, checking for overflow/underflow, and storing the outcome in destination
.
An additional fee to be included in the transaction.
Performs a bitwise and
on first
and second
, storing the outcome in destination
.
Asserts two operands are equal to each other.
Asserts two operands are not equal to each other.
A binary literal operation.
The Merkle path for the state tree blocks.
The Merkle tree for the block state.
BHP256 is a collision-resistant function that processes inputs in 256-bit chunks.
BHP512 is a collision-resistant function that processes inputs in 512-bit chunks.
BHP768 is a collision-resistant function that processes inputs in 768-bit chunks.
BHP1024 is a collision-resistant function that processes inputs in 1024-bit chunks.
Pedersen64 is a collision-resistant function that processes inputs in 64-bit chunks.
Pedersen128 is a collision-resistant function that processes inputs in 128-bit chunks.
Computes whether first
is greater than second
as a boolean, storing the outcome in destination
.
Computes whether first
is greater than or equal to second
as a boolean, storing the outcome in destination
.
BHP256 is a collision-resistant hash function that processes inputs in 256-bit chunks.
BHP512 is a collision-resistant hash function that processes inputs in 512-bit chunks.
BHP768 is a collision-resistant hash function that processes inputs in 768-bit chunks.
BHP1024 is a collision-resistant hash function that processes inputs in 1024-bit chunks.
Pedersen64 is a collision-resistant hash function that processes inputs in 64-bit chunks.
Pedersen128 is a collision-resistant hash function that processes inputs in 128-bit chunks.
Poseidon2 is a cryptographic hash function that processes inputs in 2-field chunks.
Poseidon4 is a cryptographic hash function that processes inputs in 4-field chunks.
Poseidon8 is a cryptographic hash function that processes inputs in 8-field chunks.
The Merkle path for the block header.
Computes the multiplicative inverse of first
, storing the outcome in destination
.
Computes whether first
equals second
as a boolean, storing the outcome in destination
.
Computes whether first
does not equals second
as a boolean, storing the outcome in destination
.
Computes whether first
is less than second
as a boolean, storing the outcome in destination
.
Computes whether first
is less than or equal to second
as a boolean, storing the outcome in destination
.
Performs a bitwise or
on first
and second
, storing the outcome in destination
.
A ternary literal operation.
The Merkle path for a function or transition in the transaction.
The Merkle path for transaction in a block.
The Merkle path for an input or output ID in the transition.
A unary literal operation.
Performs a bitwise xor
on first
and second
, storing the outcome in destination
.