mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-01-05 14:53:06 +00:00
add pda_seeds field
This commit is contained in:
parent
a3e07347a4
commit
d82f06593d
@ -12,12 +12,17 @@ pub struct ProgramInput<T> {
|
||||
pub instruction: T,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone)]
|
||||
#[cfg_attr(any(feature = "host", test), derive(Debug, PartialEq, Eq))]
|
||||
pub struct PdaSeed([u8; 32]);
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone)]
|
||||
#[cfg_attr(any(feature = "host", test), derive(Debug, PartialEq, Eq))]
|
||||
pub struct ChainedCall {
|
||||
pub program_id: ProgramId,
|
||||
pub instruction_data: InstructionData,
|
||||
pub pre_states: Vec<AccountWithMetadata>,
|
||||
pub pda_seeds: Vec<PdaSeed>
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone)]
|
||||
|
||||
@ -107,6 +107,7 @@ impl PublicTransaction {
|
||||
program_id: message.program_id,
|
||||
instruction_data: message.instruction_data.clone(),
|
||||
pre_states: input_pre_states,
|
||||
pda_seeds: vec![],
|
||||
};
|
||||
|
||||
let mut chained_calls = VecDeque::from_iter([initial_call]);
|
||||
|
||||
@ -25,6 +25,7 @@ fn main() {
|
||||
program_id,
|
||||
instruction_data: instruction_data.clone(),
|
||||
pre_states: vec![receiver_pre.clone(), sender_pre.clone()], // <- Account order permutation here
|
||||
pda_seeds: vec![]
|
||||
};
|
||||
num_chain_calls as usize - 1
|
||||
];
|
||||
@ -33,6 +34,7 @@ fn main() {
|
||||
program_id,
|
||||
instruction_data,
|
||||
pre_states: vec![receiver_pre.clone(), sender_pre.clone()], // <- Account order permutation here
|
||||
pda_seeds: vec![],
|
||||
});
|
||||
|
||||
write_nssa_outputs_with_chained_call(
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user