Skip to content

Commit 8c78f03

Browse files
committed
unify wasm32 as wasm
1 parent 7c37a92 commit 8c78f03

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

asm_egui/src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ mod top_bar;
88
mod targets;
99

1010
fn main() {
11-
#[cfg(target_arch = "wasm32")]
11+
#[cfg(target_family = "wasm")]
1212
targets::wasm::main();
1313

14-
#[cfg(not(target_arch = "wasm32"))]
14+
#[cfg(not(target_family = "wasm"))]
1515
targets::native::main().ok();
1616
}
1717

asm_egui/src/targets/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#[cfg(target_arch = "wasm32")]
1+
#[cfg(target_family = "wasm")]
22
pub mod wasm;
3-
#[cfg(not(target_arch = "wasm32"))]
3+
#[cfg(not(target_family = "wasm"))]
44
pub mod native;

asm_server/src/server.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ impl AsmServer {
214214
if let Err(e) = write_result {
215215
error!("save file {source_key} meets an error. {e:?}");
216216
};
217-
#[cfg(not(target_arch = "wasm32"))] {
217+
#[cfg(not(target_family = "wasm"))] {
218218
let saved_path = write_access.guess_path();
219219
let parent_path = saved_path.parent().unwrap_or(saved_path.as_path());
220220
if !parent_path.exists() { return; };

0 commit comments

Comments
 (0)