Compare commits

...

1 commit

Author SHA1 Message Date
bb75c41f13
try 1 2024-01-06 10:33:55 +01:00
2 changed files with 3 additions and 3 deletions

View file

@ -56,7 +56,7 @@ use nom::{combinator::into, IResult};
/// String::from_utf8_lossy(email.child.as_text().unwrap().body), /// String::from_utf8_lossy(email.child.as_text().unwrap().body),
/// ); /// );
/// ``` /// ```
pub fn parse_message(input: &[u8]) -> IResult<&[u8], part::composite::Message> { pub fn parse_message<'a>(input: &'a [u8]) -> IResult<&'a[u8], part::composite::Message<'a>> {
into(part::composite::message(mime::MIME::< into(part::composite::message(mime::MIME::<
mime::r#type::DeductibleMessage, mime::r#type::DeductibleMessage,
>::default()))(input) >::default()))(input)
@ -99,6 +99,6 @@ pub fn parse_message(input: &[u8]) -> IResult<&[u8], part::composite::Message> {
/// imf.subject.unwrap().to_string(), /// imf.subject.unwrap().to_string(),
/// ); /// );
/// ``` /// ```
pub fn parse_imf(input: &[u8]) -> IResult<&[u8], imf::Imf> { pub fn parse_imf<'a>(input: &'a [u8]) -> IResult<&'a [u8], imf::Imf<'a>> {
imf::imf(input) imf::imf(input)
} }

View file

@ -28,7 +28,7 @@ pub enum MIMEWord<'a> {
Quoted(QuotedString<'a>), Quoted(QuotedString<'a>),
Atom(&'a [u8]), Atom(&'a [u8]),
} }
impl Default for MIMEWord<'static> { impl<'a> Default for MIMEWord<'a> {
fn default() -> Self { fn default() -> Self {
Self::Atom(&[]) Self::Atom(&[])
} }