File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -162,7 +162,7 @@ pub fn match_byte(input: TokenStream) -> TokenStream {
162
162
for ( i, ref arm) in arms. iter ( ) . enumerate ( ) {
163
163
let case_id = i + 1 ;
164
164
let index = case_id as isize ;
165
- let name = syn:: Ident :: new ( & format ! ( "Case{}" , case_id ) , arm. span ( ) ) ;
165
+ let name = syn:: Ident :: new ( & format ! ( "Case{case_id}" ) , arm. span ( ) ) ;
166
166
let pat = & arm. pat ;
167
167
parse_pat_to_table ( pat, case_id as u8 , & mut wildcard, & mut table) ;
168
168
@@ -177,7 +177,7 @@ pub fn match_byte(input: TokenStream) -> TokenStream {
177
177
178
178
let mut table_content = Vec :: new ( ) ;
179
179
for entry in table. iter ( ) {
180
- let name: syn:: Path = syn:: parse_str ( & format ! ( "Case::Case{}" , entry ) ) . unwrap ( ) ;
180
+ let name: syn:: Path = syn:: parse_str ( & format ! ( "Case::Case{entry}" ) ) . unwrap ( ) ;
181
181
table_content. push ( name) ;
182
182
}
183
183
let table = quote:: quote!( static __CASES: [ Case ; 256 ] = [ #( #table_content) , * ] ; ) ;
Original file line number Diff line number Diff line change @@ -80,11 +80,11 @@ impl fmt::Display for BasicParseErrorKind<'_> {
80
80
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
81
81
match self {
82
82
BasicParseErrorKind :: UnexpectedToken ( token) => {
83
- write ! ( f, "unexpected token: {:?}" , token )
83
+ write ! ( f, "unexpected token: {token :?}" )
84
84
}
85
85
BasicParseErrorKind :: EndOfInput => write ! ( f, "unexpected end of input" ) ,
86
86
BasicParseErrorKind :: AtRuleInvalid ( rule) => {
87
- write ! ( f, "invalid @ rule encountered: '@{}'" , rule )
87
+ write ! ( f, "invalid @ rule encountered: '@{rule }'" )
88
88
}
89
89
BasicParseErrorKind :: AtRuleBodyInvalid => write ! ( f, "invalid @ rule body encountered" ) ,
90
90
BasicParseErrorKind :: QualifiedRuleInvalid => {
You can’t perform that action at this time.
0 commit comments