@@ -62,16 +62,16 @@ fn main() {
6262 }
6363 } ;
6464
65- let day_padded = format ! ( "{:02}" , day ) ;
65+ let day_padded = format ! ( "{day :02}" ) ;
6666
67- let input_path = format ! ( "src/inputs/{}.txt" , day_padded ) ;
68- let example_path = format ! ( "src/examples/{}.txt" , day_padded ) ;
69- let module_path = format ! ( "src/bin/{}.rs" , day_padded ) ;
67+ let input_path = format ! ( "src/inputs/{day_padded }.txt" ) ;
68+ let example_path = format ! ( "src/examples/{day_padded }.txt" ) ;
69+ let module_path = format ! ( "src/bin/{day_padded }.rs" ) ;
7070
7171 let mut file = match safe_create_file ( & module_path) {
7272 Ok ( file) => file,
7373 Err ( e) => {
74- eprintln ! ( "Failed to create module file: {}" , e ) ;
74+ eprintln ! ( "Failed to create module file: {e}" ) ;
7575 process:: exit ( 1 ) ;
7676 }
7777 } ;
@@ -81,7 +81,7 @@ fn main() {
8181 println ! ( "Created module file \" {}\" " , & module_path) ;
8282 }
8383 Err ( e) => {
84- eprintln ! ( "Failed to write module contents: {}" , e ) ;
84+ eprintln ! ( "Failed to write module contents: {e}" ) ;
8585 process:: exit ( 1 ) ;
8686 }
8787 }
@@ -91,7 +91,7 @@ fn main() {
9191 println ! ( "Created empty input file \" {}\" " , & input_path) ;
9292 }
9393 Err ( e) => {
94- eprintln ! ( "Failed to create input file: {}" , e ) ;
94+ eprintln ! ( "Failed to create input file: {e}" ) ;
9595 process:: exit ( 1 ) ;
9696 }
9797 }
@@ -101,7 +101,7 @@ fn main() {
101101 println ! ( "Created empty example file \" {}\" " , & example_path) ;
102102 }
103103 Err ( e) => {
104- eprintln ! ( "Failed to create example file: {}" , e ) ;
104+ eprintln ! ( "Failed to create example file: {e}" ) ;
105105 process:: exit ( 1 ) ;
106106 }
107107 }
0 commit comments