Skip to content

Commit 004c923

Browse files
committed
fix: move drop
1 parent e288b8b commit 004c923

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/commands/run.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -505,6 +505,10 @@ fn populate_with_wasi(
505505
if wasi_modules.wasi_threads {
506506
#[cfg(not(feature = "wasi-threads"))]
507507
{
508+
// Silence the unused warning for `module` as it is only used in the
509+
// conditionally-compiled wasi-threads.
510+
drop(&module);
511+
508512
bail!("Cannot enable wasi-threads when the binary is not compiled with this feature.");
509513
}
510514
#[cfg(feature = "wasi-threads")]
@@ -519,10 +523,6 @@ fn populate_with_wasi(
519523
}
520524
}
521525

522-
// Silence the unused warning for `module` as it is only used in the
523-
// conditionally-compiled wasi-threads.
524-
drop(&module);
525-
526526
Ok(())
527527
}
528528

0 commit comments

Comments
 (0)