File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -431,7 +431,7 @@ struct Host {
431431fn populate_with_wasi (
432432 host : & mut Host ,
433433 linker : & mut Linker < Host > ,
434- _module : Module ,
434+ module : Module ,
435435 preopen_dirs : Vec < ( String , Dir ) > ,
436436 argv : & [ String ] ,
437437 vars : & [ ( String , String ) ] ,
@@ -510,16 +510,20 @@ fn populate_with_wasi(
510510 }
511511 #[ cfg( feature = "wasi-threads" ) ]
512512 {
513- wasmtime_wasi_threads:: add_to_linker ( linker, & _module , |host| {
513+ wasmtime_wasi_threads:: add_to_linker ( linker, & module , |host| {
514514 host. wasi_threads . as_ref ( ) . unwrap ( )
515515 } ) ?;
516516 host. wasi_threads = Some ( Arc :: new ( WasiThreadsCtx :: new (
517- _module ,
517+ module ,
518518 Arc :: new ( linker. clone ( ) ) ,
519519 ) ?) ) ;
520520 }
521521 }
522522
523+ // Silence the unused warning for `module` as it is only used in the
524+ // conditionally-compiled wasi-threads.
525+ drop ( & module) ;
526+
523527 Ok ( ( ) )
524528}
525529
You can’t perform that action at this time.
0 commit comments