Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tlv-account-resolution/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ solana-account-info = "3.0.0"
solana-instruction = { version = "3.0.0", features = ["std"] }
solana-program-error = "3.0.0"
solana-pubkey = { version = "3.0.0", features = ["curve25519"] }
solana-zero-copy = { version = "1.0.0", features = ["bytemuck"] }
spl-discriminator = { version = "0.5.1", path = "../discriminator" }
spl-list-view = { version = "0.1.1", path = "../list-view" }
spl-pod = { version = "0.7.4", path = "../pod" }
spl-type-length-value = { version = "0.9.1", path = "../type-length-value" }
thiserror = "2.0"

Expand Down
6 changes: 3 additions & 3 deletions tlv-account-resolution/src/account.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ use {
solana_instruction::AccountMeta,
solana_program_error::ProgramError,
solana_pubkey::{Pubkey, PUBKEY_BYTES},
spl_pod::primitives::PodBool,
solana_zero_copy::unaligned::Bool,
};

/// Resolve a program-derived address (PDA) from the instruction data
Expand Down Expand Up @@ -129,9 +129,9 @@ pub struct ExtraAccountMeta {
/// data used to derive the pubkey (account or instruction data).
pub address_config: [u8; 32],
/// Whether the account should sign
pub is_signer: PodBool,
pub is_signer: Bool,
/// Whether the account should be writable
pub is_writable: PodBool,
pub is_writable: Bool,
}
/// Helper used to know when the top bit is set, to interpret the
/// discriminator as an index rather than as a type
Expand Down
6 changes: 3 additions & 3 deletions tlv-account-resolution/src/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ use {
solana_instruction::{AccountMeta, Instruction},
solana_program_error::ProgramError,
solana_pubkey::Pubkey,
solana_zero_copy::unaligned::U32,
spl_discriminator::SplDiscriminate,
spl_list_view::{ListView, ListViewReadOnly},
spl_pod::primitives::PodU32,
spl_type_length_value::state::{TlvState, TlvStateBorrowed, TlvStateMut},
std::future::Future,
};
Expand Down Expand Up @@ -189,9 +189,9 @@ impl ExtraAccountMetaList {
/// `TlvStateBorrowed`. I hope there's a better way to do this!
pub fn unpack_with_tlv_state<'a, T: SplDiscriminate>(
tlv_state: &'a TlvStateBorrowed,
) -> Result<ListViewReadOnly<'a, ExtraAccountMeta, PodU32>, ProgramError> {
) -> Result<ListViewReadOnly<'a, ExtraAccountMeta, U32>, ProgramError> {
let bytes = tlv_state.get_first_bytes::<T>()?;
ListView::<ExtraAccountMeta, PodU32>::unpack(bytes)
ListView::<ExtraAccountMeta, U32>::unpack(bytes)
}

/// Get the byte size required to hold `num_items` items
Expand Down
Loading