Skip to content

Commit 4404288

Browse files
committed
style: Make clippy happy
1 parent cdcabd6 commit 4404288

File tree

1 file changed

+0
-32
lines changed

1 file changed

+0
-32
lines changed

src/git2_config.rs

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -421,38 +421,6 @@ pub(crate) trait Parseable: Sized {
421421
fn parse(s: &str) -> anyhow::Result<Self>;
422422
}
423423

424-
pub(crate) struct ParseWrapper<T>(pub(crate) T);
425-
426-
impl<T: std::fmt::Display> std::fmt::Display for ParseWrapper<T> {
427-
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
428-
self.0.fmt(f)
429-
}
430-
}
431-
432-
impl<T> std::str::FromStr for ParseWrapper<T>
433-
where
434-
T: std::str::FromStr,
435-
T::Err: Into<anyhow::Error>,
436-
{
437-
type Err = anyhow::Error;
438-
439-
fn from_str(s: &str) -> Result<Self, Self::Err> {
440-
T::from_str(s).map(ParseWrapper).map_err(|e| e.into())
441-
}
442-
}
443-
444-
impl<T> Parseable for ParseWrapper<T>
445-
where
446-
T: Parseable,
447-
T: std::str::FromStr,
448-
T: std::fmt::Display,
449-
T::Err: Into<anyhow::Error>,
450-
{
451-
fn parse(s: &str) -> anyhow::Result<Self> {
452-
<Self as std::str::FromStr>::from_str(s)
453-
}
454-
}
455-
456424
pub(crate) trait Field {
457425
type Output;
458426

0 commit comments

Comments
 (0)