drop default from PhantomData::default() (#30476)

This commit is contained in:
Jeff Washington (jwash) 2023-02-23 16:59:08 -06:00 committed by GitHub
parent 5aa5aef1a9
commit 2441a06e78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 9 additions and 9 deletions

View File

@ -96,7 +96,7 @@ impl<'b, T: Clone + Copy + 'b> Bucket<T> {
drives, drives,
index, index,
data: vec![], data: vec![],
_phantom: PhantomData::default(), _phantom: PhantomData,
stats, stats,
reallocated: Reallocated::default(), reallocated: Reallocated::default(),
} }

View File

@ -305,7 +305,7 @@ pub fn new_cluster_nodes<T: 'static>(
nodes, nodes,
index, index,
weighted_shuffle, weighted_shuffle,
_phantom: PhantomData::default(), _phantom: PhantomData,
} }
} }

View File

@ -1653,7 +1653,7 @@ impl<C: Column + ColumnName> CompactionFilterFactory for PurgedSlotFilterFactory
copied_oldest_slot copied_oldest_slot
)) ))
.unwrap(), .unwrap(),
_phantom: PhantomData::default(), _phantom: PhantomData,
} }
} }
@ -1696,7 +1696,7 @@ fn get_cf_options<C: 'static + Column + ColumnName>(
cf_options.set_compaction_filter_factory(PurgedSlotFilterFactory::<C> { cf_options.set_compaction_filter_factory(PurgedSlotFilterFactory::<C> {
oldest_slot: oldest_slot.clone(), oldest_slot: oldest_slot.clone(),
name: CString::new(format!("purged_slot_filter_factory({})", C::NAME)).unwrap(), name: CString::new(format!("purged_slot_filter_factory({})", C::NAME)).unwrap(),
_phantom: PhantomData::default(), _phantom: PhantomData,
}); });
} }
@ -1878,7 +1878,7 @@ pub mod tests {
let mut factory = PurgedSlotFilterFactory::<ShredData> { let mut factory = PurgedSlotFilterFactory::<ShredData> {
oldest_slot: oldest_slot.clone(), oldest_slot: oldest_slot.clone(),
name: CString::new("test compaction filter").unwrap(), name: CString::new("test compaction filter").unwrap(),
_phantom: PhantomData::default(), _phantom: PhantomData,
}; };
let mut compaction_filter = factory.create(dummy_compaction_filter_context()); let mut compaction_filter = factory.create(dummy_compaction_filter_context());

View File

@ -258,7 +258,7 @@ impl<T: IndexValue, U: IndexValue + From<T> + Into<T>> BucketMapHolder<T, U> {
startup: AtomicBool::default(), startup: AtomicBool::default(),
mem_budget_mb, mem_budget_mb,
threads, threads,
_phantom: PhantomData::default(), _phantom: PhantomData,
} }
} }

View File

@ -69,7 +69,7 @@ impl TryFrom<AccountSharedData> for StakeAccount<()> {
Ok(Self { Ok(Self {
account, account,
stake_state, stake_state,
_phantom: PhantomData::default(), _phantom: PhantomData,
}) })
} }
} }
@ -86,7 +86,7 @@ impl TryFrom<AccountSharedData> for StakeAccount<Delegation> {
Ok(Self { Ok(Self {
account: stake_account.account, account: stake_account.account,
stake_state: stake_account.stake_state, stake_state: stake_account.stake_state,
_phantom: PhantomData::default(), _phantom: PhantomData,
}) })
} }
} }
@ -97,7 +97,7 @@ impl From<StakeAccount<Delegation>> for StakeAccount<()> {
Self { Self {
account: stake_account.account, account: stake_account.account,
stake_state: stake_account.stake_state, stake_state: stake_account.stake_state,
_phantom: PhantomData::default(), _phantom: PhantomData,
} }
} }
} }