Commit 42fe6e62 authored by clabby's avatar clabby Committed by GitHub

Improve `IBigStepper` docs (#9118)

parent e7058c94
......@@ -4,8 +4,8 @@ pragma solidity ^0.8.15;
import { IPreimageOracle } from "src/cannon/interfaces/IPreimageOracle.sol";
/// @title IBigStepper
/// @notice An interface for a contract with a state transition function that
/// will accept a pre state and return a post state.
/// @notice Describes a state machine that can perform a single instruction step, provided a prestate and an optional
/// proof.
/// ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀
/// ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢀⣼⠶⢅⠒⢄⢔⣶⡦⣤⡤⠄⣀⠀⠀⠀⠀⠀⠀⠀
/// ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠨⡏⠀⠀⠈⠢⣙⢯⣄⠀⢨⠯⡺⡘⢄⠀⠀⠀⠀⠀
......@@ -25,13 +25,13 @@ import { IPreimageOracle } from "src/cannon/interfaces/IPreimageOracle.sol";
/// ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠉⠉⠉⠙⠛⠻⠿⠿⠿⢿⣿⣿⣿⣷⣶⣶⣾⣿⣿⣿⣿⠿⠟⠁
/// ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠈⠉⠉⠉⠉⠁⠀⠀⠀⠀⠀
interface IBigStepper {
/// @notice Performs a single instruction step from a given prestate and returns the poststate
/// hash.
/// @param _stateData The preimage of the prestate hash.
/// @param _proof A proof for the inclusion of the prestate's memory in the merkle tree.
/// @param _localContext The local key context for the preimage oracle. Optional, can be set as a constant
/// if the caller only requires one set of local keys.
/// @return postState_ The poststate hash after the instruction step.
/// @notice Performs the state transition from a given prestate and returns the hash of the post state witness.
/// @param _stateData The raw opaque prestate data.
/// @param _proof Opaque proof data, can be used to prove things about the prestate in relation to the state of the
/// interface's implementation.
/// @param _localContext The local key context for the preimage oracle. Optional, can be set as a constant if the
/// implementation only requires one set of local keys.
/// @return postState_ The hash of the post state witness after the state transition.
function step(
bytes calldata _stateData,
bytes calldata _proof,
......@@ -40,6 +40,6 @@ interface IBigStepper {
external
returns (bytes32 postState_);
/// @notice Returns the preimage oracle used by the stepper.
/// @notice Returns the preimage oracle used by the state machine.
function oracle() external view returns (IPreimageOracle oracle_);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment