Remove unneeded lifetime bounds

This commit is contained in:
Aode (Lion) 2021-10-14 18:08:43 -05:00
parent 14ac47e805
commit 1ea13c35fe
6 changed files with 55 additions and 60 deletions

54
Cargo.lock generated
View file

@ -165,9 +165,9 @@ checksum = "631ae5198c9be5e753e5cc215e1bd73c2b466a3565173db433f52bb9d3e66dba"
[[package]]
name = "cc"
version = "1.0.70"
version = "1.0.71"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d26a6ce4b6a484fa3edb70f7efa6fc430fd2b87285fe8b84304fd0936faa0dc0"
checksum = "79c2681d6594606957bbb8631c4b90a7fcaaa72cdb714743a437b156d6a7eedd"
[[package]]
name = "cfg-if"
@ -653,9 +653,9 @@ dependencies = [
[[package]]
name = "ppv-lite86"
version = "0.2.10"
version = "0.2.14"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ac74c624d6b2d21f425f752262f42188365d7b8ff1aff74c82e45136510a4857"
checksum = "c3ca011bd0129ff4ae15cd04c4eef202cadf6c51c21e47aba319b4e0501db741"
[[package]]
name = "proc-macro-crate"
@ -681,18 +681,18 @@ checksum = "bc881b2c22681370c6a780e47af9840ef841837bc98118431d4e1868bd0c1086"
[[package]]
name = "proc-macro2"
version = "1.0.29"
version = "1.0.30"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b9f5105d4fdaab20335ca9565e106a5d9b82b6219b5ba735731124ac6711d23d"
checksum = "edc3358ebc67bc8b7fa0c007f945b0b18226f78437d61bec735a9eb96b61ee70"
dependencies = [
"unicode-xid",
]
[[package]]
name = "quote"
version = "1.0.9"
version = "1.0.10"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c3d0b9745dc2debf507c8422de05d7226cc1f0644216dfdfead988f9b1ab32a7"
checksum = "38bc8cc6a5f2e3655e0899c1b848643b2562f853f114bfec7be120678e3ace05"
dependencies = [
"proc-macro2",
]
@ -850,9 +850,9 @@ checksum = "2579985fda508104f7587689507983eadd6a6e84dd35d6d115361f530916fa0d"
[[package]]
name = "sharded-slab"
version = "0.1.3"
version = "0.1.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "740223c51853f3145fe7c90360d2d4232f2b62e3449489c207eccde818979982"
checksum = "900fba806f70c630b0a382d0d825e17a0f19fcd059a2ade1ff237bcddf446b31"
dependencies = [
"lazy_static",
]
@ -868,9 +868,9 @@ dependencies = [
[[package]]
name = "slab"
version = "0.4.4"
version = "0.4.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c307a32c1c5c437f38c7fd45d753050587732ba8628319fbdf12a7e289ccc590"
checksum = "9def91fd1e018fe007022791f865d0ccc9b3a0d5001e01aabb8b40e46000afb5"
[[package]]
name = "slotmap"
@ -943,9 +943,9 @@ dependencies = [
[[package]]
name = "syn"
version = "1.0.78"
version = "1.0.80"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a4eac2e6c19f5c3abc0c229bea31ff0b9b091c7b14990e8924b92902a303a0c0"
checksum = "d010a1623fbd906d51d650a9916aaefc05ffa0e4053ff7fe601167f3e715d194"
dependencies = [
"proc-macro2",
"quote",
@ -954,18 +954,18 @@ dependencies = [
[[package]]
name = "thiserror"
version = "1.0.29"
version = "1.0.30"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "602eca064b2d83369e2b2f34b09c70b605402801927c65c11071ac911d299b88"
checksum = "854babe52e4df1653706b98fcfc05843010039b406875930a70e4d9644e5c417"
dependencies = [
"thiserror-impl",
]
[[package]]
name = "thiserror-impl"
version = "1.0.29"
version = "1.0.30"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bad553cc2c78e8de258400763a647e80e6d1b31ee237275d756f6836d204494c"
checksum = "aa32fd3f627f367fe16f893e2597ae3c05020f8bba2666a4e6ea73d377e5714b"
dependencies = [
"proc-macro2",
"quote",
@ -1004,7 +1004,7 @@ dependencies = [
[[package]]
name = "tokio-actors"
version = "0.1.0"
source = "git+https://git.asonix.dog/asonix/tokio-actors?branch=main#708f94263f769a92add9312deae71d26242dc594"
source = "git+https://git.asonix.dog/asonix/tokio-actors?branch=main#20af812c2c293e0956596a6d2a012307a1436814"
dependencies = [
"once_cell",
"tokio",
@ -1014,9 +1014,9 @@ dependencies = [
[[package]]
name = "tokio-macros"
version = "1.4.1"
version = "1.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "154794c8f499c2619acd19e839294703e9e32e7630ef5f46ea80d4ef0fbee5eb"
checksum = "b2dd85aeaba7b68df939bd357c6afb36c87951be9e80bf9c859f2fc3e9fca0fd"
dependencies = [
"proc-macro2",
"quote",
@ -1047,9 +1047,9 @@ dependencies = [
[[package]]
name = "tracing"
version = "0.1.28"
version = "0.1.29"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "84f96e095c0c82419687c20ddf5cb3eadb61f4e1405923c9dc8e53a1adacbda8"
checksum = "375a639232caf30edfc78e8d89b2d4c375515393e7af7e16f01cd96917fb2105"
dependencies = [
"cfg-if 1.0.0",
"pin-project-lite",
@ -1059,9 +1059,9 @@ dependencies = [
[[package]]
name = "tracing-attributes"
version = "0.1.17"
version = "0.1.18"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c4f915eb6abf914599c200260efced9203504c4c37380af10cdf3b7d36970650"
checksum = "f4f480b8f81512e825f337ad51e94c1eb5d3bbdf2b363dcd01e2b19a9ffe3f8e"
dependencies = [
"proc-macro2",
"quote",
@ -1110,9 +1110,9 @@ dependencies = [
[[package]]
name = "tracing-subscriber"
version = "0.2.24"
version = "0.2.25"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fdd0568dbfe3baf7048b7908d2b32bca0d81cd56bec6d2a8f894b01d74f86be3"
checksum = "0e0d2eaa99c3c2e41547cfa109e910a68ea03823cccad4a0525dcbc9b01e8c71"
dependencies = [
"ansi_term",
"chrono",

View file

@ -99,10 +99,10 @@ impl Manager {
}
#[tracing::instrument(skip(ctx))]
async fn turn<'a>(
&'a mut self,
async fn turn(
&mut self,
msg: ManagerMessage,
ctx: &'a mut Context<ManagerMessage>,
ctx: &mut Context<ManagerMessage>,
) -> tokio_actors::Result<()> {
match msg {
ManagerMessage::Found(port_name) => self.found(port_name, ctx).await,
@ -113,10 +113,10 @@ impl Manager {
}
#[tracing::instrument(skip(ctx))]
async fn on_remove<'a>(
&'a mut self,
async fn on_remove(
&mut self,
child_id: usize,
ctx: &'a mut Context<ManagerMessage>,
ctx: &mut Context<ManagerMessage>,
) -> tokio_actors::Result<()> {
let mut inner = self.inner.write().await;

View file

@ -24,10 +24,10 @@ impl Connector {
}
#[tracing::instrument(skip(ctx))]
pub(super) async fn turn<'a>(
&'a mut self,
pub(super) async fn turn(
&mut self,
port_name: String,
ctx: &'a mut Context<String>,
ctx: &mut Context<String>,
) -> tokio_actors::Result<()> {
tracing::debug!("Connector");
ctx.stop();
@ -57,7 +57,6 @@ impl Connector {
let info = DeckInfo::new(identity, author, repo, version);
// TODO: Run connection logic
let deck = Deck::build(
port,
self.connection.clone(),

View file

@ -138,10 +138,10 @@ impl Deck {
}
#[tracing::instrument(skip(_ctx))]
pub(super) async fn turn<'a>(
&'a mut self,
pub(super) async fn turn(
&mut self,
msg: DeckMessage,
_ctx: &'a mut Context<DeckMessage>,
_ctx: &mut Context<DeckMessage>,
) -> tokio_actors::Result<()> {
match msg {
DeckMessage::Press(key) => self.press(key).await,
@ -149,9 +149,9 @@ impl Deck {
}
#[tracing::instrument(skip(ctx))]
pub(super) async fn on_start<'a>(
&'a mut self,
ctx: &'a mut Context<DeckMessage>,
pub(super) async fn on_start(
&mut self,
ctx: &mut Context<DeckMessage>,
) -> tokio_actors::Result<()> {
let mut inner = self.inner.write().await;
@ -166,9 +166,9 @@ impl Deck {
}
#[tracing::instrument(skip(_ctx))]
pub(super) async fn on_stop<'a>(
&'a mut self,
_ctx: &'a mut Context<DeckMessage>,
pub(super) async fn on_stop(
&mut self,
_ctx: &mut Context<DeckMessage>,
) -> tokio_actors::Result<()> {
self.connection
.object_server_mut()
@ -179,10 +179,10 @@ impl Deck {
}
#[tracing::instrument(skip(ctx))]
pub(super) async fn on_remove<'a>(
&'a mut self,
pub(super) async fn on_remove(
&mut self,
child_id: usize,
ctx: &'a mut Context<DeckMessage>,
ctx: &mut Context<DeckMessage>,
) -> tokio_actors::Result<()> {
let mut inner = self.inner.write().await;

View file

@ -25,9 +25,9 @@ impl Port {
}
#[tracing::instrument(skip(ctx))]
pub(super) async fn on_start<'a>(
&'a mut self,
ctx: &'a mut Context<PortMessage>,
pub(super) async fn on_start(
&mut self,
ctx: &mut Context<PortMessage>,
) -> tokio_actors::Result<()> {
ctx.stop_on_error();
ctx.handle().send(PortMessage::Start).await?;
@ -36,10 +36,10 @@ impl Port {
}
#[tracing::instrument(skip(ctx))]
pub(super) async fn turn<'a>(
&'a mut self,
pub(super) async fn turn(
&mut self,
msg: PortMessage,
ctx: &'a mut Context<PortMessage>,
ctx: &mut Context<PortMessage>,
) -> tokio_actors::Result<()> {
match msg {
PortMessage::Start => self.start(ctx).await,

View file

@ -29,11 +29,7 @@ impl Searcher {
}
#[tracing::instrument(skip(_ctx))]
pub(super) async fn turn<'a>(
&'a mut self,
_: (),
_ctx: &'a mut Context<()>,
) -> tokio_actors::Result<()> {
pub(super) async fn turn(&mut self, _: (), _ctx: &mut Context<()>) -> tokio_actors::Result<()> {
let ports = tokio::task::block_in_place(|| tokio_serial::available_ports())?;
let port_names = ports