From d31ccf10c38bc1e2c97c71102ab6ae1a2161b54b Mon Sep 17 00:00:00 2001 From: Thomas Hurst Date: Tue, 4 Sep 2018 22:18:53 +0100 Subject: Use Struct { foo } over Struct { foo: foo } clippy:redundant_field_names --- src/lib.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index c1be8aa..237706c 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -554,8 +554,8 @@ pub fn parse_content_type(header: &str) -> ParsedContentType { ); ParsedContentType { - mimetype: mimetype, - charset: charset, + mimetype, + charset, params: params.params, } } @@ -628,7 +628,7 @@ pub fn parse_content_disposition(header: &str) -> ParsedContentDisposition { let params = parse_param_content(header); let disposition = parse_disposition_type(¶ms.value); ParsedContentDisposition { - disposition: disposition, + disposition, params: params.params, } } @@ -775,8 +775,8 @@ pub fn parse_mail(raw_data: &[u8]) -> Result { .unwrap_or_default(); let mut result = ParsedMail { - headers: headers, - ctype: ctype, + headers, + ctype, body: &raw_data[ix_body..], subparts: Vec::::new(), }; -- cgit v1.2.3