diff --git a/docs/architecture/transactions/procedures.md b/docs/architecture/transactions/procedures.md index 85cc9b9c8..d52f8409d 100644 --- a/docs/architecture/transactions/procedures.md +++ b/docs/architecture/transactions/procedures.md @@ -9,7 +9,7 @@ There are user-facing procedures and kernel procedures. Users don't directly inv These procedures can be used to create smart contract/account code, note scripts, or account scripts. They basically serve as an API for the underlying kernel procedures. If a procedure can be called in the current context, an `exec` is sufficient. Otherwise the context procedures must be invoked by `call`. Users never need to invoke `syscall` procedures themselves. !!! tip - If capitalized, a variable representing a `word`, e.g., `ACCT_HASH` consists of four `felts`. If lowercase, the variable is represented by a single `felt`. +If capitalized, a variable representing a `word`, e.g., `ACCT_HASH` consists of four `felts`. If lowercase, the variable is represented by a single `felt`. ### Account @@ -37,24 +37,26 @@ Any procedure that changes the account state must be invoked in the account cont To import the note procedures, set `use.miden::note` at the beginning of the file. All procedures are restricted to the note context. -| Procedure name | Inputs | Outputs | Context | Description | -| --------------------- | -------------------------- | ------------------------ | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `get_assets` | `[dest_ptr]` | `[num_assets, dest_ptr]` | note | | -| `get_inputs` | `[dest_ptr]` | `[dest_ptr]` | note | | -| `get_sender` | `[]` | `[sender]` | note | | -| `compute_inputs_hash` | `[inputs_ptr, num_inputs]` | `[HASH]` | note | | +| Procedure name | Inputs | Outputs | Context | Description | +| ------------------------ | -------------------------- | ------------------------ | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `get_assets` | `[dest_ptr]` | `[num_assets, dest_ptr]` | note | | +| `get_inputs` | `[dest_ptr]` | `[dest_ptr]` | note | | +| `get_sender` | `[]` | `[sender]` | note | | +| `compute_inputs_hash` | `[inputs_ptr, num_inputs]` | `[HASH]` | note | | +| `get_note_serial_number` | `[]` | `[SERIAL_NUMBER]` | note | | +| `get_script_hash` | `[]` | `[SCRIPT_HASH]` | note | | ### Tx To import the transaction procedures set `use.miden::tx` at the beginning of the file. Only the `create_note` procedure is restricted to the account context. -| Procedure name | Inputs | Outputs | Context | Description | -| ----------------------- | ------------------------- | ------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `get_block_number` | `[]` | `[num]` | account, note |