mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-08-24 22:29:22 +00:00
add type aliases
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
use nssa_core::program::{
|
||||
AccountPostState, BlockId, ProgramInput, ProgramOutput, Timestamp, ValidityWindow,
|
||||
AccountPostState, BlockValidityWindow, ProgramInput, ProgramOutput, TimestampValidityWindow,
|
||||
read_nssa_inputs,
|
||||
};
|
||||
|
||||
type Instruction = (ValidityWindow<BlockId>, ValidityWindow<Timestamp>);
|
||||
type Instruction = (BlockValidityWindow, TimestampValidityWindow);
|
||||
|
||||
fn main() {
|
||||
let (
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use nssa_core::program::{
|
||||
AccountPostState, BlockId, ChainedCall, ProgramId, ProgramInput, ProgramOutput, Timestamp,
|
||||
ValidityWindow, read_nssa_inputs,
|
||||
AccountPostState, BlockValidityWindow, ChainedCall, ProgramId, ProgramInput, ProgramOutput,
|
||||
TimestampValidityWindow, read_nssa_inputs,
|
||||
};
|
||||
use risc0_zkvm::serde::to_vec;
|
||||
|
||||
@@ -9,9 +9,9 @@ use risc0_zkvm::serde::to_vec;
|
||||
///
|
||||
/// Instruction: (`window`, `chained_program_id`, `chained_window`)
|
||||
/// The initial output uses `window` and chains to `chained_program_id` with `chained_window`.
|
||||
/// The chained program (validity_window) expects `(ValidityWindow<BlockId>, ValidityWindow<Timestamp>)`
|
||||
/// The chained program (validity_window) expects `(BlockValidityWindow, TimestampValidityWindow)`
|
||||
/// so an unbounded timestamp window is appended automatically.
|
||||
type Instruction = (ValidityWindow<BlockId>, ProgramId, ValidityWindow<BlockId>);
|
||||
type Instruction = (BlockValidityWindow, ProgramId, BlockValidityWindow);
|
||||
|
||||
fn main() {
|
||||
let (
|
||||
@@ -27,7 +27,7 @@ fn main() {
|
||||
|
||||
let chained_instruction = to_vec(&(
|
||||
chained_block_validity_window,
|
||||
ValidityWindow::<Timestamp>::new_unbounded(),
|
||||
TimestampValidityWindow::new_unbounded(),
|
||||
))
|
||||
.unwrap();
|
||||
let chained_call = ChainedCall {
|
||||
|
||||
Reference in New Issue
Block a user