Skip to content

Commit

Permalink
Silence Clippy warning on assigning_clones
Browse files Browse the repository at this point in the history
  • Loading branch information
sirhcel committed May 10, 2024
1 parent 95a78ea commit cb88008
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,8 @@ pub struct SerialPortBuilder {

impl SerialPortBuilder {
/// Set the path to the serial port
// TODO: Switch to `clone_into` when bumping our MSRV past 1.63 and remove this exemption.
#[allow(clippy::assigning_clones)]
#[must_use]
pub fn path<'a>(mut self, path: impl Into<std::borrow::Cow<'a, str>>) -> Self {
self.path = path.into().as_ref().to_owned();
Expand Down

0 comments on commit cb88008

Please sign in to comment.