Make clippy to be happy (#30394)
* replace default implementation with default enum * fix format to make clippy happy
This commit is contained in:
parent
f91e63dfe9
commit
ee1717b24b
|
@ -2820,7 +2820,7 @@ impl Node {
|
|||
}
|
||||
pub fn new_localhost_with_pubkey(pubkey: &Pubkey) -> Self {
|
||||
let localhost_ip_addr = IpAddr::V4(Ipv4Addr::LOCALHOST);
|
||||
let localhost_bind_addr = format!("{:?}:0", localhost_ip_addr);
|
||||
let localhost_bind_addr = format!("{localhost_ip_addr:?}:0");
|
||||
let unspecified_bind_addr = format!("{:?}:0", IpAddr::V4(Ipv4Addr::UNSPECIFIED));
|
||||
let port_range = (1024, 65535);
|
||||
|
||||
|
|
|
@ -48,8 +48,10 @@ pub trait WorkingSlot {
|
|||
fn is_ancestor(&self, other: Slot) -> bool;
|
||||
}
|
||||
|
||||
#[derive(Default)]
|
||||
pub enum LoadedProgramType {
|
||||
/// Tombstone for undeployed, closed or unloadable programs
|
||||
#[default]
|
||||
Invalid,
|
||||
LegacyV0(VerifiedExecutable<RequisiteVerifier, InvokeContext<'static>>),
|
||||
LegacyV1(VerifiedExecutable<RequisiteVerifier, InvokeContext<'static>>),
|
||||
|
@ -68,12 +70,6 @@ impl Debug for LoadedProgramType {
|
|||
}
|
||||
}
|
||||
|
||||
impl Default for LoadedProgramType {
|
||||
fn default() -> Self {
|
||||
LoadedProgramType::Invalid
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, Default)]
|
||||
pub struct LoadedProgram {
|
||||
/// The program of this entry
|
||||
|
|
Loading…
Reference in New Issue