Skip to content

Commit

Permalink
Use derive-where instead of unmaintained derivative
Browse files Browse the repository at this point in the history
  • Loading branch information
ryoqun committed Oct 31, 2024
1 parent 4994762 commit 438a8fe
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 6 deletions.
13 changes: 12 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ ctrlc = "3.4.5"
curve25519-dalek = { version = "4.1.3", features = ["digest", "rand_core"] }
dashmap = "5.5.3"
derivation-path = { version = "0.2.0", default-features = false }
derivative = "2.2.0"
derive-where = "1.2.7"
dialoguer = "0.10.4"
digest = "0.10.7"
dir-diff = "0.3.3"
Expand Down
13 changes: 12 additions & 1 deletion programs/sbf/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion unified-scheduler-pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ edition = { workspace = true }
assert_matches = { workspace = true }
crossbeam-channel = { workspace = true }
dashmap = { workspace = true }
derivative = { workspace = true }
derive-where = { workspace = true }
log = { workspace = true }
qualifier_attr = { workspace = true }
scopeguard = { workspace = true }
Expand Down
4 changes: 2 additions & 2 deletions unified-scheduler-pool/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ use {
crossbeam_channel::{self, never, select_biased, Receiver, RecvError, SendError, Sender},
dashmap::DashMap,
derivative::Derivative,
derive_where::derive_where,
log::*,
scopeguard::defer,
solana_ledger::blockstore_processor::{
Expand Down Expand Up @@ -569,8 +570,7 @@ mod chained_channel {

// P doesn't need to be `: Clone`, yet rustc derive can't handle it.
// see https://github.com/rust-lang/rust/issues/26925
#[derive(Derivative)]
#[derivative(Clone(bound = "C: Clone"))]
#[derive_where(Clone)]
pub(super) struct ChainedChannelReceiver<P, C: Clone> {
receiver: Receiver<ChainedChannel<P, C>>,
aux_receiver: Receiver<P>,
Expand Down

0 comments on commit 438a8fe

Please sign in to comment.