carbon_system_program_decoder/instructions/
upgrade_nonce_account.rs1use carbon_core::{borsh, CarbonDeserialize};
2
3#[derive(
4 CarbonDeserialize, Debug, serde::Serialize, serde::Deserialize, PartialEq, Eq, Clone, Hash,
5)]
6#[carbon(discriminator = "0x0c000000")]
7pub struct UpgradeNonceAccount {}
8
9pub struct UpgradeNonceAccountInstructionAccounts {
10 pub nonce_account: solana_pubkey::Pubkey,
11}
12
13impl carbon_core::deserialize::ArrangeAccounts for UpgradeNonceAccount {
14 type ArrangedAccounts = UpgradeNonceAccountInstructionAccounts;
15
16 fn arrange_accounts(
17 accounts: &[solana_instruction::AccountMeta],
18 ) -> Option<Self::ArrangedAccounts> {
19 let [nonce_account, _remaining @ ..] = accounts else {
20 return None;
21 };
22
23 Some(UpgradeNonceAccountInstructionAccounts {
24 nonce_account: nonce_account.pubkey,
25 })
26 }
27}