Don't use move semantics if not needed (#8793)

This commit is contained in:
Jack May
2020-03-11 14:37:23 -07:00
committed by GitHub
parent 5f5824d78d
commit 6eb4973780
32 changed files with 133 additions and 137 deletions

View File

@@ -926,7 +926,7 @@ mod tests {
.unwrap();
let allocate_with_seed = Message::new_with_payer(
vec![system_instruction::allocate_with_seed(
&[system_instruction::allocate_with_seed(
&alice_with_seed,
&alice_pubkey,
seed,
@@ -978,7 +978,7 @@ mod tests {
let bank = Arc::new(Bank::new_from_parent(&bank, &collector, bank.slot() + 1));
let bank_client = BankClient::new_shared(&bank);
let ix = system_instruction::create_account(&alice_pubkey, &bob_pubkey, 0, len1, &program);
let message = Message::new(vec![ix]);
let message = Message::new(&[ix]);
let r = bank_client.send_message(&[&alice_keypair, &bob_keypair], message);
assert!(r.is_ok());
@@ -996,7 +996,7 @@ mod tests {
let bank = Arc::new(Bank::new_from_parent(&bank, &collector, bank.slot() + 1));
let bank_client = BankClient::new_shared(&bank);
let ix = system_instruction::create_account(&alice_pubkey, &bob_pubkey, 1, len2, &program);
let message = Message::new(vec![ix]);
let message = Message::new(&[ix]);
let r = bank_client.send_message(&[&alice_keypair, &bob_keypair], message);
assert!(r.is_ok());
}
@@ -1036,7 +1036,7 @@ mod tests {
.unwrap();
let assign_with_seed = Message::new_with_payer(
vec![system_instruction::assign_with_seed(
&[system_instruction::assign_with_seed(
&alice_with_seed,
&alice_pubkey,
seed,