1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-06-27 07:19:04 +02:00

clippy warnings

This commit is contained in:
Nikolay Kim
2019-12-08 00:46:51 +06:00
parent 8df33f7a81
commit 6c9f9fff73
73 changed files with 222 additions and 207 deletions

View File

@ -98,7 +98,7 @@ impl Charset {
}
impl Display for Charset {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.write_str(self.label())
}
}

View File

@ -27,7 +27,7 @@ pub enum Encoding {
}
impl fmt::Display for Encoding {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.write_str(match *self {
Chunked => "chunked",
Brotli => "br",

View File

@ -113,7 +113,7 @@ impl EntityTag {
}
impl Display for EntityTag {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
if self.weak {
write!(f, "W/\"{}\"", self.tag)
} else {

View File

@ -28,7 +28,7 @@ impl FromStr for HttpDate {
}
impl Display for HttpDate {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
fmt::Display::fmt(&self.0.to_utc().rfc822(), f)
}
}

View File

@ -53,7 +53,7 @@ impl<T: PartialEq> cmp::PartialOrd for QualityItem<T> {
}
impl<T: fmt::Display> fmt::Display for QualityItem<T> {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
fmt::Display::fmt(&self.item, f)?;
match self.quality.0 {
1000 => Ok(()),