Skip to content

Commit

Permalink
Emit a better error when using mio on wasm (#1856)
Browse files Browse the repository at this point in the history
Signed-off-by: Alice Ryhl <[email protected]>
  • Loading branch information
Darksonn authored Jan 21, 2025
1 parent 2471197 commit edc0c76
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@
//!
//! The available features are described in the [`features`] module.
#[cfg(all(target_family = "wasm", not(target_os = "wasi")))]
compile_error!("This wasm target is unsupported by mio. If using Tokio, disable the net feature.");

// macros used internally
#[macro_use]
mod macros;
Expand Down

0 comments on commit edc0c76

Please sign in to comment.