@hapax The trick is to cast them to function type. Each function and callback has unique non-nameable type, but most can be cast to a regular type.
If you support closures with data, then you need Box<dyn Fn()>.
@kornel That was the trick! Using crossbeam also helped me be able to store the hashmap in a struct and be able to spawn threads with the saved Boxed functions.
This is a server created by Jahziel Villasana (aka hapax). He's not sure what he's going to use it for yet...