@@ -31,7 +31,7 @@ impl ModuleRegistry {
31
31
}
32
32
}
33
33
fn register ( & mut self , name : String , addr : ModuleInstanceAddr ) {
34
- log:: debug!( "registering module: {}" , name ) ;
34
+ log:: debug!( "registering module: {name}" ) ;
35
35
self . modules . insert ( name. clone ( ) , addr) ;
36
36
37
37
self . last_module = Some ( addr) ;
@@ -99,22 +99,22 @@ impl TestSuite {
99
99
} ) ;
100
100
101
101
let print_i32 = Extern :: typed_func ( |_ctx : tinywasm:: FuncContext , arg : i32 | {
102
- log:: debug!( "print_i32: {}" , arg ) ;
102
+ log:: debug!( "print_i32: {arg}" ) ;
103
103
Ok ( ( ) )
104
104
} ) ;
105
105
106
106
let print_i64 = Extern :: typed_func ( |_ctx : tinywasm:: FuncContext , arg : i64 | {
107
- log:: debug!( "print_i64: {}" , arg ) ;
107
+ log:: debug!( "print_i64: {arg}" ) ;
108
108
Ok ( ( ) )
109
109
} ) ;
110
110
111
111
let print_f32 = Extern :: typed_func ( |_ctx : tinywasm:: FuncContext , arg : f32 | {
112
- log:: debug!( "print_f32: {}" , arg ) ;
112
+ log:: debug!( "print_f32: {arg}" ) ;
113
113
Ok ( ( ) )
114
114
} ) ;
115
115
116
116
let print_f64 = Extern :: typed_func ( |_ctx : tinywasm:: FuncContext , arg : f64 | {
117
- log:: debug!( "print_f64: {}" , arg ) ;
117
+ log:: debug!( "print_f64: {arg}" ) ;
118
118
Ok ( ( ) )
119
119
} ) ;
120
120
@@ -148,7 +148,7 @@ impl TestSuite {
148
148
. define ( "spectest" , "print_f64_f64" , print_f64_f64) ?;
149
149
150
150
for ( name, addr) in modules {
151
- log:: debug!( "registering module: {}" , name ) ;
151
+ log:: debug!( "registering module: {name}" ) ;
152
152
imports. link_module ( name, * addr) ?;
153
153
}
154
154
@@ -158,7 +158,7 @@ impl TestSuite {
158
158
pub fn run_files < ' a > ( & mut self , tests : impl IntoIterator < Item = TestFile < ' a > > ) -> Result < ( ) > {
159
159
tests. into_iter ( ) . for_each ( |group| {
160
160
let name = group. name ( ) ;
161
- println ! ( "running group: {}" , name ) ;
161
+ println ! ( "running group: {name}" ) ;
162
162
if self . 1 . contains ( & name. to_string ( ) ) {
163
163
info ! ( "skipping group: {name}" ) ;
164
164
self . test_group ( & format ! ( "{name} (skipped)" ) , name) ;
@@ -217,7 +217,7 @@ impl TestSuite {
217
217
. map_err ( |e| eyre ! ( "failed to parse wat module: {:?}" , try_downcast_panic( e) ) ) ;
218
218
219
219
match & result {
220
- Err ( err) => debug ! ( "failed to parse module: {:?}" , err ) ,
220
+ Err ( err) => debug ! ( "failed to parse module: {err :?}" ) ,
221
221
Ok ( ( name, module) ) => module_registry. update_last_module ( module. id ( ) , name. clone ( ) ) ,
222
222
} ;
223
223
@@ -402,7 +402,7 @@ impl TestSuite {
402
402
let args = convert_wastargs ( invoke. args ) ?;
403
403
let module = module_registry. get_idx ( invoke. module ) ;
404
404
exec_fn_instance ( module, & mut store, invoke. name , & args) . map_err ( |e| {
405
- error ! ( "failed to execute function: {:?}" , e ) ;
405
+ error ! ( "failed to execute function: {e :?}" ) ;
406
406
e
407
407
} ) ?;
408
408
Ok ( ( ) )
@@ -413,7 +413,7 @@ impl TestSuite {
413
413
}
414
414
415
415
AssertReturn { span, exec, results } => {
416
- info ! ( "AssertReturn: {:?}" , exec ) ;
416
+ info ! ( "AssertReturn: {exec :?}" ) ;
417
417
let expected = match convert_wastret ( results. into_iter ( ) ) {
418
418
Err ( err) => {
419
419
test_group. add_result (
@@ -489,11 +489,11 @@ impl TestSuite {
489
489
490
490
let invoke_name = invoke. name ;
491
491
let res: Result < Result < ( ) > , _ > = catch_unwind_silent ( || {
492
- debug ! ( "invoke: {:?}" , invoke ) ;
492
+ debug ! ( "invoke: {invoke :?}" ) ;
493
493
let args = convert_wastargs ( invoke. args ) ?;
494
494
let module = module_registry. get_idx ( invoke. module ) ;
495
495
let outcomes = exec_fn_instance ( module, & mut store, invoke. name , & args) . map_err ( |e| {
496
- error ! ( "failed to execute function: {:?}" , e ) ;
496
+ error ! ( "failed to execute function: {e :?}" ) ;
497
497
e
498
498
} ) ?;
499
499
0 commit comments