Upgrade Rust to 1.52.0 (#17096)

* Upgrade Rust to 1.52.0
update nightly_version to newly pushed docker image
fix clippy lint errors
1.52 comes with grcov 0.8.0, include this version to script

* upgrade to Rust 1.52.1

* disabling Serum from downstream projects until it is upgraded to Rust 1.52.1
This commit is contained in:
Tao Zhu
2021-05-19 09:31:47 -05:00
committed by GitHub
parent 4788976517
commit 0781fe1b4f
54 changed files with 345 additions and 423 deletions

View File

@ -865,12 +865,12 @@ mod tests {
instructions: vec![],
};
let demote_sysvar_write_locks = true;
assert_eq!(message.is_writable(0, demote_sysvar_write_locks), true);
assert_eq!(message.is_writable(1, demote_sysvar_write_locks), false);
assert_eq!(message.is_writable(2, demote_sysvar_write_locks), false);
assert_eq!(message.is_writable(3, demote_sysvar_write_locks), true);
assert_eq!(message.is_writable(4, demote_sysvar_write_locks), true);
assert_eq!(message.is_writable(5, demote_sysvar_write_locks), false);
assert!(message.is_writable(0, demote_sysvar_write_locks));
assert!(!message.is_writable(1, demote_sysvar_write_locks));
assert!(!message.is_writable(2, demote_sysvar_write_locks));
assert!(message.is_writable(3, demote_sysvar_write_locks));
assert!(message.is_writable(4, demote_sysvar_write_locks));
assert!(!message.is_writable(5, demote_sysvar_write_locks));
}
#[test]

View File

@ -133,11 +133,10 @@ pub fn create_test_recent_blockhashes(start: usize) -> RecentBlockhashes {
)
})
.collect();
let bhq: Vec<_> = blocks
blocks
.iter()
.map(|(i, hash, fee_calc)| IterItem(*i, hash, fee_calc))
.collect();
bhq.into_iter().collect()
.collect()
}
#[cfg(test)]

View File

@ -700,8 +700,8 @@ pub mod tests {
assert_eq!(account.data().len(), 2);
assert_eq!(account.owner, key);
assert_eq!(account.owner(), &key);
assert_eq!(account.executable, true);
assert_eq!(account.executable(), true);
assert!(account.executable);
assert!(account.executable());
assert_eq!(account.rent_epoch, 4);
assert_eq!(account.rent_epoch(), 4);
let account = account2;
@ -711,8 +711,8 @@ pub mod tests {
assert_eq!(account.data().len(), 2);
assert_eq!(account.owner, key);
assert_eq!(account.owner(), &key);
assert_eq!(account.executable, true);
assert_eq!(account.executable(), true);
assert!(account.executable);
assert!(account.executable());
assert_eq!(account.rent_epoch, 4);
assert_eq!(account.rent_epoch(), 4);
}

View File

@ -72,6 +72,7 @@ impl fmt::Debug for Packet {
}
}
#[allow(clippy::uninit_assumed_init)]
impl Default for Packet {
fn default() -> Packet {
Packet {