Skip to content

Commit

Permalink
clippy: elide lifetimes
Browse files Browse the repository at this point in the history
  • Loading branch information
lovasoa committed Nov 6, 2024
1 parent cc7acdb commit 83425a9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "good_lp"
version = "1.9.0"
version = "1.10.0"
authors = ["Ophir LOJKINE <contact@ophir.dev>"]
edition = "2018"
repository = "https://github.com/rust-or/good_lp"
Expand Down
2 changes: 1 addition & 1 deletion src/expression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ impl IntoAffineExpression for LinearExpression {
#[doc(hidden)]
pub struct CopiedCoefficients<'a>(std::collections::hash_map::Iter<'a, Variable, f64>);

impl<'a> Iterator for CopiedCoefficients<'a> {
impl Iterator for CopiedCoefficients<'_> {
type Item = (Variable, f64);

#[inline]
Expand Down
4 changes: 2 additions & 2 deletions src/variable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ impl IntoAffineExpression for Option<Variable> {
}
}

impl<'a> IntoAffineExpression for &'a Variable {
impl IntoAffineExpression for &Variable {
type Iter = std::iter::Once<(Variable, f64)>;

#[inline]
Expand Down Expand Up @@ -412,7 +412,7 @@ struct DisplayExpr<'a, 'b, V> {
value: &'b V,
}

impl<'a, 'b, V: FormatWithVars> Display for DisplayExpr<'a, 'b, V> {
impl<V: FormatWithVars> Display for DisplayExpr<'_, '_, V> {
fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result {
self.value.format_with(f, |f, var| {
let mut name = &self.problem.variables[var.index].name;
Expand Down

0 comments on commit 83425a9

Please sign in to comment.