diff --git a/instant-xml-macros/Cargo.toml b/instant-xml-macros/Cargo.toml index b37ea5a..fb59668 100644 --- a/instant-xml-macros/Cargo.toml +++ b/instant-xml-macros/Cargo.toml @@ -2,6 +2,7 @@ name = "instant-xml-macros" version = "0.1.0" edition = "2021" +rust-version = "1.58" workspace = ".." license = "Apache-2.0 OR MIT" diff --git a/instant-xml-macros/src/ser.rs b/instant-xml-macros/src/ser.rs index 7ea8e51..322717d 100644 --- a/instant-xml-macros/src/ser.rs +++ b/instant-xml-macros/src/ser.rs @@ -271,7 +271,7 @@ fn named_field( quote!(""), syn::Error::new( field_meta.ns.uri.span(), - &format!("unknown prefix `{prefix}` (prefix must be defined on the field's type)"), + format!("unknown prefix `{prefix}` (prefix must be defined on the field's type)"), ) .into_compile_error(), ), diff --git a/instant-xml/Cargo.toml b/instant-xml/Cargo.toml index af1b0a6..32d6c15 100644 --- a/instant-xml/Cargo.toml +++ b/instant-xml/Cargo.toml @@ -2,6 +2,7 @@ name = "instant-xml" version = "0.1.0" edition = "2021" +rust-version = "1.58" workspace = ".." license = "Apache-2.0 OR MIT" diff --git a/instant-xml/src/de.rs b/instant-xml/src/de.rs index e313117..7d4c268 100644 --- a/instant-xml/src/de.rs +++ b/instant-xml/src/de.rs @@ -322,10 +322,10 @@ impl<'xml> Iterator for Context<'xml> { return Some(Ok(Node::Text(text.as_str()))); } Ok(Token::Declaration { .. }) => match self.stack.is_empty() { - false => return Some(Err(Error::UnexpectedToken(format!("{:?}", token)))), + false => return Some(Err(Error::UnexpectedToken(format!("{token:?}")))), true => {} }, - Ok(token) => return Some(Err(Error::UnexpectedToken(format!("{:?}", token)))), + Ok(token) => return Some(Err(Error::UnexpectedToken(format!("{token:?}")))), Err(e) => return Some(Err(Error::Parse(e))), } } diff --git a/instant-xml/src/ser.rs b/instant-xml/src/ser.rs index 773c8ca..b469f61 100644 --- a/instant-xml/src/ser.rs +++ b/instant-xml/src/ser.rs @@ -86,7 +86,7 @@ impl<'xml, W: fmt::Write + ?Sized> Serializer<'xml, W> { return Err(Error::UnexpectedState("invalid state for scalar")); } - self.output.write_fmt(format_args!("{}", value))?; + self.output.write_fmt(format_args!("{value}"))?; self.state = State::Element; Ok(()) }