Use no_main to allow xtasks to compile on wasm

This commit is contained in:
Connor Fitzgerald authored and Andreas Reich committed 2025-04-27 18:34:52 +02:00
1 parent fa702f9141
commit 8235cd2932
4 files changed
+8 -2

No files matched your search

+1 -1
View File
@@ -5,7 +5,7 @@ edition = "2021"
publish = false
rust-version = "1.84"
[dependencies]
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
anyhow = "1"
env_logger = { version = "0.11.0", default-features = false }
glob = "0.3.1"
+3
View File
@@ -1,3 +1,6 @@
#![cfg_attr(target_arch = "wasm32", no_main)]
#![cfg(not(target_arch = "wasm32"))]
use std::process::ExitCode;
use anyhow::Context;
+1 -1
View File
@@ -11,7 +11,7 @@ unexpected_cfgs = { level = "warn", check-cfg = [
'cfg(trick_rust_analyzer_into_highlighting_interpolated_bits)',
] }
[dependencies]
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
# The dependencies in this config have no transitive dependencies.
anyhow = "1.0.71"
env_logger = { version = "0.11.0", default-features = false }
+3
View File
@@ -1,3 +1,6 @@
#![cfg_attr(target_arch = "wasm32", no_main)]
#![cfg(not(target_arch = "wasm32"))]
use std::process::ExitCode;
use anyhow::Context;