Skip to content
This repository was archived by the owner on Mar 11, 2025. It is now read-only.

Commit 53b5574

Browse files
committed
Use the new package everywhere
1 parent f817cee commit 53b5574

File tree

32 files changed

+62
-55
lines changed

32 files changed

+62
-55
lines changed

Cargo.lock

Lines changed: 19 additions & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

associated-token-account/client/src/instruction.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
//! Instruction creators for the program
22
use {
3-
crate::{id, address::get_associated_token_address_with_program_id},
3+
crate::{address::get_associated_token_address_with_program_id, id},
44
solana_program::{
55
instruction::{AccountMeta, Instruction},
6-
pubkey::Pubkey, system_program,
6+
pubkey::Pubkey,
7+
system_program,
78
},
89
};
910

associated-token-account/program-test/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,6 @@ solana-program = "2.0.3"
1515
solana-program-test = "2.0.3"
1616
solana-sdk = "2.0.3"
1717
spl-associated-token-account = { version = "4.0.0", path = "../program", features = ["no-entrypoint"] }
18+
spl-associated-token-account-client = { version = "1.0.0", path = "../client" }
1819
spl-token = { version = "6.0", path = "../../token/program", features = ["no-entrypoint"] }
1920
spl-token-2022 = { version = "4.0.0", path = "../../token/program-2022", features = ["no-entrypoint"] }

associated-token-account/program-test/tests/create_idempotent.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ use {
2121
create_associated_token_account, create_associated_token_account_idempotent,
2222
},
2323
},
24-
spl_associated_token_address::get_associated_token_address_with_program_id,
24+
spl_associated_token_account_client::address::get_associated_token_address_with_program_id,
2525
spl_token_2022::{
2626
extension::ExtensionType,
2727
instruction::initialize_account,

associated-token-account/program-test/tests/extended_mint.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ use {
1414
transaction::{Transaction, TransactionError},
1515
},
1616
spl_associated_token_account::instruction::create_associated_token_account,
17-
spl_associated_token_address::get_associated_token_address_with_program_id,
17+
spl_associated_token_account_client::address::get_associated_token_address_with_program_id,
1818
spl_token_2022::{
1919
error::TokenError,
2020
extension::{

associated-token-account/program-test/tests/process_create_associated_token_account.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use {
1313
transaction::{Transaction, TransactionError},
1414
},
1515
spl_associated_token_account::instruction::create_associated_token_account,
16-
spl_associated_token_address::get_associated_token_address_with_program_id,
16+
spl_associated_token_account_client::address::get_associated_token_address_with_program_id,
1717
spl_token_2022::{extension::ExtensionType, state::Account},
1818
};
1919

associated-token-account/program-test/tests/recover_nested.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ use {
1515
transaction::{Transaction, TransactionError},
1616
},
1717
spl_associated_token_account::instruction,
18-
spl_associated_token_address::get_associated_token_address_with_program_id,
18+
spl_associated_token_account_client::address::get_associated_token_address_with_program_id,
1919
spl_token_2022::{
2020
extension::{ExtensionType, StateWithExtensionsOwned},
2121
state::{Account, Mint},

associated-token-account/program-test/tests/spl_token_create.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ use {
1212
solana_program_test::*,
1313
solana_sdk::{program_pack::Pack, signature::Signer, transaction::Transaction},
1414
spl_associated_token_account::instruction::create_associated_token_account,
15-
spl_associated_token_address::get_associated_token_address,
15+
spl_associated_token_account_client::address::get_associated_token_address,
1616
spl_token::state::Account,
1717
};
1818

associated-token-account/program/src/instruction.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
//! Program instructions
22
33
use borsh::{BorshDeserialize, BorshSchema, BorshSerialize};
4-
pub use spl_associated_token_account_client::intruction::*;
4+
pub use spl_associated_token_account_client::instruction::*;
55

66
/// Instructions supported by the AssociatedTokenAccount program
7-
#[deprecated(since = "4.1.0", note = "Use instructions in `spl-associated-token-account-client` crate instead.")]
87
#[derive(Clone, Debug, PartialEq, BorshDeserialize, BorshSerialize, BorshSchema)]
98
pub enum AssociatedTokenAccountInstruction {
109
/// Creates an associated token account for the given wallet address and

associated-token-account/program/src/lib.rs

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,16 @@ use solana_program::{
1616
pubkey::Pubkey,
1717
sysvar,
1818
};
19-
19+
#[deprecated(
20+
since = "4.1.0",
21+
note = "Use `spl-associated-token-account-client` crate instead."
22+
)]
23+
pub use spl_associated_token_account_client::address::{
24+
get_associated_token_address, get_associated_token_address_with_program_id,
25+
};
2026
// Export current SDK types for downstream users building with a different SDK
2127
// version
22-
pub use {solana_program, spl_associated_token_account_client::{id, ID, check_id}};
23-
#[deprecated(since = "4.1.0", note = "Use `spl-associated-token-account-client` crate instead.")]
24-
pub use spl_associated_token_account_client::{get_associated_token_address, get_associated_token_address_with_program_id};
28+
pub use spl_associated_token_account_client::{check_id, id, ID};
2529

2630
/// Create an associated token account for the given wallet address and token
2731
/// mint

0 commit comments

Comments
 (0)