Rename program_utils.rs (#8127)

This commit is contained in:
Jack May 2020-02-05 12:48:30 -08:00 committed by GitHub
parent 3ac0192d40
commit 8436457e75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 32 additions and 32 deletions

View File

@ -27,10 +27,10 @@ use solana_sdk::{
fee_calculator::FeeCalculator,
hash::Hash,
instruction::InstructionError,
instruction_processor_utils::DecodeError,
loader_instruction,
message::Message,
native_token::lamports_to_sol,
program_utils::DecodeError,
pubkey::Pubkey,
signature::{keypair_from_seed, Keypair, KeypairUtil, Signature},
system_instruction::{create_address_with_seed, SystemError, MAX_ADDRESS_SEED_LEN},

View File

@ -14,8 +14,8 @@ use solana_ledger::{
snapshot_utils,
};
use solana_sdk::{
clock::Slot, genesis_config::GenesisConfig, instruction_processor_utils::limited_deserialize,
native_token::lamports_to_sol, pubkey::Pubkey,
clock::Slot, genesis_config::GenesisConfig, native_token::lamports_to_sol,
program_utils::limited_deserialize, pubkey::Pubkey,
};
use solana_vote_program::vote_state::VoteState;
use std::{

View File

@ -33,7 +33,7 @@ use solana_sdk::{
clock::{Slot, UnixTimestamp, DEFAULT_TICKS_PER_SECOND, MS_PER_TICK},
genesis_config::GenesisConfig,
hash::Hash,
instruction_processor_utils::limited_deserialize,
program_utils::limited_deserialize,
pubkey::Pubkey,
signature::{Keypair, KeypairUtil, Signature},
timing::timestamp,

View File

@ -336,7 +336,7 @@ dependencies = [
"log 0.4.8 (registry+https://github.com/rust-lang/crates.io-index)",
"publicsuffix 1.5.3 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.44 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
"try_from 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"url 1.7.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1666,7 +1666,7 @@ dependencies = [
"mime_guess 2.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"rustls 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.44 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_urlencoded 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.42 (registry+https://github.com/rust-lang/crates.io-index)",
"tokio 0.1.22 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1872,7 +1872,7 @@ dependencies = [
[[package]]
name = "serde_json"
version = "1.0.44"
version = "1.0.46"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"itoa 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2184,7 +2184,7 @@ dependencies = [
"rayon 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.44 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-bpf-loader-program 0.24.0",
"solana-logger 0.24.0",
"solana-measure 0.24.0",
@ -2222,7 +2222,7 @@ dependencies = [
"serde 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_bytes 0.11.2 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_derive 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.44 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)",
"sha2 0.8.1 (registry+https://github.com/rust-lang/crates.io-index)",
"solana-crate-features 0.24.0",
"solana-logger 0.24.0",
@ -2857,7 +2857,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"cfg-if 0.1.9 (registry+https://github.com/rust-lang/crates.io-index)",
"serde 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.44 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)",
"wasm-bindgen-macro 0.2.58 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -3251,7 +3251,7 @@ dependencies = [
"checksum serde 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)" = "414115f25f818d7dfccec8ee535d76949ae78584fc4f79a6f45a904bf8ab4449"
"checksum serde_bytes 0.11.2 (registry+https://github.com/rust-lang/crates.io-index)" = "45af0182ff64abaeea290235eb67da3825a576c5d53e642c4d5b652e12e6effc"
"checksum serde_derive 1.0.104 (registry+https://github.com/rust-lang/crates.io-index)" = "128f9e303a5a29922045a830221b8f78ec74a5f544944f3d5984f8ec3895ef64"
"checksum serde_json 1.0.44 (registry+https://github.com/rust-lang/crates.io-index)" = "48c575e0cc52bdd09b47f330f646cf59afc586e9c4e3ccd6fc1f625b8ea1dad7"
"checksum serde_json 1.0.46 (registry+https://github.com/rust-lang/crates.io-index)" = "21b01d7f0288608a01dca632cf1df859df6fd6ffa885300fc275ce2ba6221953"
"checksum serde_urlencoded 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)" = "642dd69105886af2efd227f75a520ec9b44a820d65bc133a9131f7d229fd165a"
"checksum serde_urlencoded 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9ec5d77e2d4c73717816afac02670d5c4f534ea95ed430442cad02e7a6e32c97"
"checksum sha2 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9eb6be24e4c23a84d7184280d2722f7f2731fcdd4a9d886efbfe4413e4847ea0"

View File

@ -9,8 +9,8 @@ use solana_sdk::{
entrypoint,
entrypoint::ProgramResult,
info,
instruction_processor_utils::DecodeError,
program_error::{PrintProgramError, ProgramError},
program_utils::DecodeError,
pubkey::Pubkey,
};
use thiserror::Error;

View File

@ -10,8 +10,8 @@ use solana_sdk::{
account::KeyedAccount,
entrypoint::SUCCESS,
instruction::InstructionError,
instruction_processor_utils::{is_executable, limited_deserialize, next_keyed_account},
loader_instruction::LoaderInstruction,
program_utils::{is_executable, limited_deserialize, next_keyed_account},
pubkey::Pubkey,
sysvar::rent,
};

View File

@ -8,7 +8,7 @@ use hex;
use log::*;
use solana_sdk::account::KeyedAccount;
use solana_sdk::instruction::InstructionError;
use solana_sdk::instruction_processor_utils::limited_deserialize;
use solana_sdk::program_utils::limited_deserialize;
use solana_sdk::pubkey::Pubkey;
pub struct SpvProcessor {}

View File

@ -6,7 +6,7 @@ use serde_derive::{Deserialize, Serialize};
use solana_sdk::{
hash::Hash,
instruction::{AccountMeta, Instruction},
instruction_processor_utils::DecodeError,
program_utils::DecodeError,
pubkey::Pubkey,
system_instruction,
};

View File

@ -10,7 +10,7 @@ use solana_sdk::{
account::KeyedAccount,
hash::hash,
instruction::InstructionError,
instruction_processor_utils::{limited_deserialize, next_keyed_account},
program_utils::{limited_deserialize, next_keyed_account},
pubkey::Pubkey,
};

View File

@ -5,7 +5,7 @@ use bincode::deserialize;
use log::*;
use solana_sdk::account::KeyedAccount;
use solana_sdk::instruction::InstructionError;
use solana_sdk::instruction_processor_utils::{limited_deserialize, next_keyed_account};
use solana_sdk::program_utils::{limited_deserialize, next_keyed_account};
use solana_sdk::pubkey::Pubkey;
pub fn process_instruction(

View File

@ -7,7 +7,7 @@ use log::*;
use solana_metrics::inc_new_counter_info;
use solana_sdk::account::KeyedAccount;
use solana_sdk::instruction::InstructionError;
use solana_sdk::instruction_processor_utils::limited_deserialize;
use solana_sdk::program_utils::limited_deserialize;
use solana_sdk::pubkey::Pubkey;
use std::cmp;

View File

@ -8,8 +8,8 @@ use solana_sdk::{
account::KeyedAccount,
account_utils::State,
instruction::InstructionError,
instruction_processor_utils::{is_executable, limited_deserialize, next_keyed_account},
move_loader::id,
program_utils::{is_executable, limited_deserialize, next_keyed_account},
pubkey::Pubkey,
sysvar::rent,
};

View File

@ -1,7 +1,7 @@
use num_derive::{FromPrimitive, ToPrimitive};
use solana_sdk::{
instruction::{AccountMeta, Instruction},
instruction_processor_utils::DecodeError,
program_utils::DecodeError,
pubkey::Pubkey,
system_instruction,
};

View File

@ -5,7 +5,7 @@ use bincode::serialize_into;
use solana_sdk::{
account::KeyedAccount,
instruction::InstructionError,
instruction_processor_utils::{limited_deserialize, next_keyed_account},
program_utils::{limited_deserialize, next_keyed_account},
pubkey::Pubkey,
};

View File

@ -8,7 +8,7 @@ use serde_derive::{Deserialize, Serialize};
use solana_sdk::{
account::{get_signers, KeyedAccount},
instruction::{AccountMeta, Instruction, InstructionError, WithSigner},
instruction_processor_utils::{limited_deserialize, next_keyed_account, DecodeError},
program_utils::{limited_deserialize, next_keyed_account, DecodeError},
pubkey::Pubkey,
system_instruction,
sysvar::{self, clock::Clock, rent::Rent, stake_history::StakeHistory, Sysvar},

View File

@ -5,7 +5,7 @@ use crate::{storage_contract::StorageAccount, storage_instruction::StorageInstru
use solana_sdk::{
account::KeyedAccount,
instruction::InstructionError,
instruction_processor_utils::limited_deserialize,
program_utils::limited_deserialize,
pubkey::Pubkey,
sysvar::{clock::Clock, rewards::Rewards, Sysvar},
};

View File

@ -5,7 +5,7 @@ use num_derive::FromPrimitive;
use serde_derive::{Deserialize, Serialize};
use solana_sdk::{
instruction::{AccountMeta, Instruction, InstructionError},
instruction_processor_utils::DecodeError,
program_utils::DecodeError,
pubkey::Pubkey,
system_instruction,
};

View File

@ -9,7 +9,7 @@ use solana_config_program::get_config_data;
use solana_sdk::{
account::{Account, KeyedAccount},
instruction::InstructionError,
instruction_processor_utils::{limited_deserialize, next_keyed_account},
program_utils::{limited_deserialize, next_keyed_account},
pubkey::Pubkey,
};
use std::cell::RefMut;

View File

@ -12,7 +12,7 @@ use solana_metrics::datapoint_debug;
use solana_sdk::{
account::{get_signers, KeyedAccount},
instruction::{AccountMeta, Instruction, InstructionError, WithSigner},
instruction_processor_utils::{limited_deserialize, next_keyed_account, DecodeError},
program_utils::{limited_deserialize, next_keyed_account, DecodeError},
pubkey::Pubkey,
system_instruction,
sysvar::{self, clock::Clock, slot_hashes::SlotHashes, Sysvar},

View File

@ -583,7 +583,7 @@ mod tests {
account::{get_signers, Account},
account_utils::StateMut,
hash::hash,
instruction_processor_utils::next_keyed_account,
program_utils::next_keyed_account,
};
use std::cell::RefCell;

View File

@ -3,8 +3,8 @@ use solana_sdk::{
account_utils::StateMut,
hash::Hash,
instruction::CompiledInstruction,
instruction_processor_utils::limited_deserialize,
nonce_state::NonceState,
program_utils::limited_deserialize,
pubkey::Pubkey,
system_instruction::SystemInstruction,
system_program,

View File

@ -3,8 +3,8 @@ use solana_sdk::{
account::{get_signers, Account, KeyedAccount},
account_utils::StateMut,
instruction::InstructionError,
instruction_processor_utils::{limited_deserialize, next_keyed_account},
nonce_state::{NonceAccount, NonceState},
program_utils::{limited_deserialize, next_keyed_account},
pubkey::Pubkey,
system_instruction::{
create_address_with_seed, SystemError, SystemInstruction, MAX_PERMITTED_DATA_LENGTH,

View File

@ -12,7 +12,6 @@ pub mod fee_calculator;
pub mod hash;
pub mod inflation;
pub mod instruction;
pub mod instruction_processor_utils;
pub mod loader_instruction;
pub mod message;
pub mod move_loader;
@ -21,6 +20,7 @@ pub mod native_token;
pub mod nonce_state;
pub mod packet;
pub mod poh_config;
pub mod program_utils;
pub mod pubkey;
pub mod rent;
pub mod rpc_port;

View File

@ -1,4 +1,4 @@
use crate::{instruction::InstructionError, instruction_processor_utils::DecodeError};
use crate::{instruction::InstructionError, program_utils::DecodeError};
use num_traits::{FromPrimitive, ToPrimitive};
use thiserror::Error;

View File

@ -1,8 +1,8 @@
use crate::{
hash::hashv,
instruction::{AccountMeta, Instruction, WithSigner},
instruction_processor_utils::DecodeError,
nonce_state::NonceState,
program_utils::DecodeError,
pubkey::Pubkey,
system_program,
sysvar::{recent_blockhashes, rent},