Reformat imports to a consistent style for imports

rustfmt.toml configuration:
        imports_granularity = "One"
         group_imports = "One"
This commit is contained in:
Michael Vines
2021-12-03 09:20:02 -08:00
parent 5a7b487e3d
commit 139d15cd84
380 changed files with 6067 additions and 5293 deletions

View File

@@ -1,12 +1,16 @@
#![feature(test)]
extern crate test;
use bincode::{deserialize, serialize};
use solana_sdk::instruction::{AccountMeta, Instruction};
use solana_sdk::message::Message;
use solana_sdk::pubkey;
use solana_sdk::sysvar::instructions;
use test::Bencher;
use {
bincode::{deserialize, serialize},
solana_sdk::{
instruction::{AccountMeta, Instruction},
message::Message,
pubkey,
sysvar::instructions,
},
test::Bencher,
};
fn make_instructions() -> Vec<Instruction> {
let meta = AccountMeta::new(pubkey::new_rand(), false);

View File

@@ -1,9 +1,7 @@
#![feature(test)]
extern crate test;
use bincode::deserialize;
use solana_sdk::short_vec::ShortVec;
use test::Bencher;
use {bincode::deserialize, solana_sdk::short_vec::ShortVec, test::Bencher};
// Return a ShortVec with 127 bytes
fn create_encoded_short_vec() -> Vec<u8> {

View File

@@ -1,12 +1,14 @@
#![feature(test)]
extern crate test;
use solana_sdk::{
account::{create_account_for_test, from_account},
hash::Hash,
slot_hashes::{Slot, SlotHashes, MAX_ENTRIES},
use {
solana_sdk::{
account::{create_account_for_test, from_account},
hash::Hash,
slot_hashes::{Slot, SlotHashes, MAX_ENTRIES},
},
test::Bencher,
};
use test::Bencher;
#[bench]
fn bench_to_from_account(b: &mut Bencher) {

View File

@@ -1,11 +1,13 @@
#![feature(test)]
extern crate test;
use solana_sdk::{
account::{create_account_for_test, from_account},
slot_history::SlotHistory,
use {
solana_sdk::{
account::{create_account_for_test, from_account},
slot_history::SlotHistory,
},
test::Bencher,
};
use test::Bencher;
#[bench]
fn bench_to_from_account(b: &mut Bencher) {