wasm cleanup

This commit is contained in:
John Smith
2022-07-12 08:02:22 -04:00
parent b73511142a
commit b9acd532db
19 changed files with 248 additions and 335 deletions
+3 -15
View File
@@ -1,21 +1,9 @@
use crate::xx::*;
pub use rust_fsm::*;
cfg_if! {
if #[cfg(target_arch = "wasm32")] {
pub type StateChangeCallback<T> = Arc<
dyn Fn(<T as StateMachineImpl>::State, <T as StateMachineImpl>::State)
+ 'static,
>;
} else {
pub type StateChangeCallback<T> = Arc<
dyn Fn(<T as StateMachineImpl>::State, <T as StateMachineImpl>::State)
+ Send
+ Sync
+ 'static,
>;
}
}
pub type StateChangeCallback<T> = Arc<
dyn Fn(<T as StateMachineImpl>::State, <T as StateMachineImpl>::State) + Send + Sync + 'static,
>;
struct CallbackStateMachineInner<T>
where