Skip to content

Commit 94a365d

Browse files
committed
Lifetime cleanup to prepare for Rust 1.84
Clippy is increasing its love of anonymous lifetimes. Change-Id: I10bcbeb976539d6e1035cab3c33b309c89099cb3 Reviewed-on: https://gerrit.readyset.name/c/readyset/+/8450 Tested-by: Buildkite CI Reviewed-by: Jason Brown <[email protected]>
1 parent b19d722 commit 94a365d

File tree

7 files changed

+18
-18
lines changed

7 files changed

+18
-18
lines changed

benchmarks/src/reporting/storage/postgres.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ impl PostgresStorage {
2828
Ok(PostgresStorage { client })
2929
}
3030

31-
async fn write_session<'a>(
32-
client: &Transaction<'a>,
31+
async fn write_session(
32+
client: &Transaction<'_>,
3333
session: &BenchSession,
3434
) -> anyhow::Result<BenchSessionId> {
3535
let query = r#"
@@ -53,8 +53,8 @@ impl PostgresStorage {
5353
Ok(session_id)
5454
}
5555

56-
async fn write_aggregate<'a>(
57-
client: &Transaction<'a>,
56+
async fn write_aggregate(
57+
client: &Transaction<'_>,
5858
session_id: BenchSessionId,
5959
metric: &str,
6060
unit: &str,

database-utils/src/connection.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -679,7 +679,7 @@ pub enum Transaction<'a> {
679679
PostgresPool(deadpool_postgres::Transaction<'a>),
680680
}
681681

682-
impl<'a> QueryableConnection for Transaction<'a> {
682+
impl QueryableConnection for Transaction<'_> {
683683
async fn query_drop<Q>(&mut self, stmt: Q) -> Result<(), DatabaseError>
684684
where
685685
Q: AsQuery + AsRef<str> + Send + Sync,
@@ -785,7 +785,7 @@ impl<'a> QueryableConnection for Transaction<'a> {
785785
}
786786
}
787787

788-
impl<'a> Transaction<'a> {
788+
impl Transaction<'_> {
789789
/// Consumes the transaction, committing the operations.
790790
pub async fn commit(self) -> Result<(), DatabaseError> {
791791
match self {

nom-sql/src/dialect.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ where
4747
}
4848
}
4949

50-
impl<'a, T> DialectDisplay for CommaSeparatedList<'a, T>
50+
impl<T> DialectDisplay for CommaSeparatedList<'_, T>
5151
where
5252
T: DialectDisplay,
5353
{

readyset-mysql/src/backend.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -378,8 +378,8 @@ macro_rules! handle_error {
378378
};
379379
}
380380

381-
async fn handle_readyset_result<'a, W>(
382-
result: noria_connector::QueryResult<'a>,
381+
async fn handle_readyset_result<W>(
382+
result: noria_connector::QueryResult<'_>,
383383
writer: QueryResultWriter<'_, W>,
384384
) -> io::Result<()>
385385
where
@@ -427,8 +427,8 @@ where
427427
}
428428
}
429429

430-
async fn handle_upstream_result<'a, W>(
431-
result: upstream::QueryResult<'a>,
430+
async fn handle_upstream_result<W>(
431+
result: upstream::QueryResult<'_>,
432432
writer: QueryResultWriter<'_, W>,
433433
) -> io::Result<()>
434434
where
@@ -478,8 +478,8 @@ where
478478
}
479479
}
480480

481-
async fn handle_execute_result<'a, W>(
482-
result: Result<QueryResult<'a, LazyUpstream<MySqlUpstream>>, Error>,
481+
async fn handle_execute_result<W>(
482+
result: Result<QueryResult<'_, LazyUpstream<MySqlUpstream>>, Error>,
483483
writer: QueryResultWriter<'_, W>,
484484
) -> io::Result<()>
485485
where
@@ -504,8 +504,8 @@ where
504504
}
505505
}
506506

507-
async fn handle_query_result<'a, W>(
508-
result: Result<QueryResult<'a, LazyUpstream<MySqlUpstream>>, Error>,
507+
async fn handle_query_result<W>(
508+
result: Result<QueryResult<'_, LazyUpstream<MySqlUpstream>>, Error>,
509509
writer: QueryResultWriter<'_, W>,
510510
) -> QueryResultsResponse
511511
where

readyset-server/src/controller/migrate/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ pub struct MigrationPlan<'df> {
342342
dmp: DomainMigrationPlan,
343343
}
344344

345-
impl<'df> MigrationPlan<'df> {
345+
impl MigrationPlan<'_> {
346346
/// Apply the migration plan to the provided `Leader`.
347347
///
348348
/// If the plan fails, the `Leader`'s state is left unchanged; however, no attempt

readyset-util/src/shared_cache.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ where
227227

228228
/// Return the *key* associated with the given value within either the local, or the shared
229229
/// versions of this cache. O(size), and performs no memoization
230-
pub async fn key_for_val<'a, U>(&'a self, val: &U) -> Option<K>
230+
pub async fn key_for_val<U>(&self, val: &U) -> Option<K>
231231
where
232232
V: PartialEq<U>,
233233
K: Clone,

replicators/src/mysql_connector/snapshot.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ fn tx_opts() -> TxOpts {
137137
tx_opts
138138
}
139139

140-
impl<'a> MySqlReplicator<'a> {
140+
impl MySqlReplicator<'_> {
141141
/// Load all the `CREATE TABLE` statements for the tables in the MySQL database. Returns the the
142142
/// transaction that holds the DDL locks for the tables and the Vector of tables that requires
143143
/// snapshot.

0 commit comments

Comments
 (0)