@@ -128,7 +128,7 @@ impl UefiOSImpl {
128128 let ( cols, rows) = ( mode. columns ( ) , mode. rows ( ) ) ;
129129 for ( msg, fg, bg) in self . ui_buf . drain ( ..) {
130130 self . vga . set_color ( fg, bg) . unwrap ( ) ;
131- write ! ( self . vga, "{}" , msg ) . unwrap ( ) ;
131+ write ! ( self . vga, "{msg}" ) . unwrap ( ) ;
132132 }
133133 self . vga . set_color ( Color :: White , Color :: Black ) . unwrap ( ) ;
134134 if self . ui_pos + 1 < cols * rows {
@@ -216,7 +216,7 @@ impl UefiOS {
216216 os. spawn ( "init" , async move {
217217 loop {
218218 if let Err ( err) = f ( os) . await {
219- log:: error!( "Error: {:?}" , err ) ;
219+ log:: error!( "Error: {err :?}" ) ;
220220 }
221221 }
222222 } ) ;
@@ -227,7 +227,7 @@ impl UefiOS {
227227
228228 if let Err ( err) = err {
229229 if err. status ( ) != Status :: UNSUPPORTED {
230- log:: error!( "Error disabling watchdog: {:?}" , err ) ;
230+ log:: error!( "Error disabling watchdog: {err :?}" ) ;
231231 }
232232
233233 break ;
@@ -361,7 +361,7 @@ impl UefiOS {
361361 let mut name_buf = vec ! [ 0u16 ; name. len( ) * 2 + 16 ] ;
362362 let name = CStr16 :: from_str_with_buf ( name, & mut name_buf) . unwrap ( ) ;
363363 let ( var, attrs) = uefi:: runtime:: get_variable_boxed ( name, vendor)
364- . map_err ( |e| Error :: Generic ( format ! ( "Error getting variable: {:?}" , e ) ) ) ?;
364+ . map_err ( |e| Error :: Generic ( format ! ( "Error getting variable: {e :?}" ) ) ) ?;
365365 Ok ( ( var. to_vec ( ) , attrs) )
366366 }
367367
@@ -376,7 +376,7 @@ impl UefiOS {
376376 let mut name_buf = vec ! [ 0u16 ; name. len( ) * 2 + 16 ] ;
377377 let name = CStr16 :: from_str_with_buf ( name, & mut name_buf) . unwrap ( ) ;
378378 uefi:: runtime:: set_variable ( name, vendor, attrs, data)
379- . map_err ( |e| Error :: Generic ( format ! ( "Error setting variable: {:?}" , e ) ) ) ?;
379+ . map_err ( |e| Error :: Generic ( format ! ( "Error setting variable: {e :?}" ) ) ) ?;
380380 Ok ( ( ) )
381381 }
382382
@@ -461,15 +461,11 @@ impl UefiOS {
461461 let mode = os. vga . current_mode ( ) . unwrap ( ) . unwrap ( ) ;
462462 let cols = mode. columns ( ) ;
463463
464- os. write_with_color (
465- & format ! ( "uptime: {:10.1}s" , time) ,
466- Color :: White ,
467- Color :: Black ,
468- ) ;
464+ os. write_with_color ( & format ! ( "uptime: {time:10.1}s" ) , Color :: White , Color :: Black ) ;
469465 os. maybe_advance_to_col ( cols / 3 ) ;
470466
471467 if let Some ( ip) = ip {
472- os. write_with_color ( & format ! ( "IP: {}" , ip ) , Color :: White , Color :: Black ) ;
468+ os. write_with_color ( & format ! ( "IP: {ip}" ) , Color :: White , Color :: Black ) ;
473469 } else {
474470 os. write_with_color ( "DHCP..." , Color :: Yellow , Color :: Black ) ;
475471 }
0 commit comments