public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: Proxmox VE development discussion <pve-devel@lists.proxmox.com>,
	Gabriel Goller <g.goller@proxmox.com>
Subject: Re: [pve-devel] [PATCH proxmox-ve-rs] clippy: elide some lifetimes
Date: Fri, 4 Apr 2025 18:50:53 +0200	[thread overview]
Message-ID: <ad2f758b-8d1f-4ac5-9299-ed0cb328a4b5@proxmox.com> (raw)
In-Reply-To: <20250331134032.376240-1-g.goller@proxmox.com>

Am 31.03.25 um 15:40 schrieb Gabriel Goller:
> Elide some lifetimes to avoid clippy warnings:
> 
>     warning: the following explicit lifetimes could be elided: 'a
>        --> proxmox-ve-config/src/firewall/parse.rs:319:11
>         |
>     319 | impl<'de, 'a, E> serde::de::Deserializer<'de> for SomeStrDeserializer<'a, E>
>         |           ^^                                                          ^^
>         |
>         = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
>         = note: `#[warn(clippy::needless_lifetimes)]` on by default
>     help: elide the lifetimes
>         |
>     319 - impl<'de, 'a, E> serde::de::Deserializer<'de> for SomeStrDeserializer<'a, E>
>     319 + impl<'de, E> serde::de::Deserializer<'de> for SomeStrDeserializer<'_, E>
>         |
> 
>     warning: the following explicit lifetimes could be elided: 'de
>        --> proxmox-ve-config/src/firewall/parse.rs:382:6
>         |
>     382 | impl<'de, 'a, E> serde::de::IntoDeserializer<'de, E> for SomeStr<'a>
>         |      ^^^                                     ^^^
>         |
>         = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
>     help: elide the lifetimes
>         |
>     382 - impl<'de, 'a, E> serde::de::IntoDeserializer<'de, E> for SomeStr<'a>
>     382 + impl<'a, E> serde::de::IntoDeserializer<'_, E> for SomeStr<'a>
>         |
> 
>     warning: the following explicit lifetimes could be elided: 'de
>        --> proxmox-ve-config/src/firewall/parse.rs:468:6
>         |
>     468 | impl<'de, E> serde::de::IntoDeserializer<'de, E> for SomeString
>         |      ^^^                                 ^^^
>         |
>         = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
>     help: elide the lifetimes
>         |
>     468 - impl<'de, E> serde::de::IntoDeserializer<'de, E> for SomeString
>     468 + impl<E> serde::de::IntoDeserializer<'_, E> for SomeString
>         |

please don't add that verbose and rather useless stuff to commit messages

And I applied the one from Christoph already, not because of above,
but simply because I read that first – but from a commit message POV
I definitively favor his one.

https://git.proxmox.com/?p=proxmox-ve-rs.git;a=commitdiff;h=1386a82556a9dfb42b0ec101cc3cf52d41848a0c


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

      reply	other threads:[~2025-04-04 16:51 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-31 13:40 Gabriel Goller
2025-04-04 16:50 ` Thomas Lamprecht [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ad2f758b-8d1f-4ac5-9299-ed0cb328a4b5@proxmox.com \
    --to=t.lamprecht@proxmox.com \
    --cc=g.goller@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal