File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ pub fn parse_expr_for_jsx(
5656 top_level_mark : Mark ,
5757) -> Arc < Box < Expr > > {
5858 let fm = cm. new_source_file (
59- FileName :: Custom ( format ! ( "<jsx-config-{}.js>" , name ) ) . into ( ) ,
59+ FileName :: Custom ( format ! ( "<jsx-config-{name }.js>" ) ) . into ( ) ,
6060 src
6161 ) ;
6262
@@ -1457,7 +1457,7 @@ fn jsx_text_to_str(t: Atom) -> Atom {
14571457 } else {
14581458 Cow :: Borrowed ( line. trim_end_matches ( ' ' ) )
14591459 } ;
1460- if line. len ( ) == 0 {
1460+ if line. is_empty ( ) {
14611461 continue ;
14621462 }
14631463 if i != 0 && !buf. is_empty ( ) {
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ enum Persist {
3939fn get_persistent_id ( ident : & Ident ) -> Persist {
4040 if ident. sym . starts_with ( |c : char | c. is_ascii_uppercase ( ) ) {
4141 if cfg ! ( debug_assertions) && ident. ctxt == SyntaxContext :: empty ( ) {
42- panic ! ( "`{}` should be resolved" , ident )
42+ panic ! ( "`{ident }` should be resolved" )
4343 }
4444 Persist :: Component ( ident. clone ( ) )
4545 } else {
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ fn assert_hygiene(e: &Expr) {
3737
3838 if let Expr :: Ident ( i) = e {
3939 if i. ctxt == SyntaxContext :: empty ( ) {
40- panic ! ( "`{}` should be resolved" , i )
40+ panic ! ( "`{i }` should be resolved" )
4141 }
4242 }
4343}
You can’t perform that action at this time.
0 commit comments