Note, you have to be quite careful with typeid - you can end up with types not matching because you have two different versions of a crate.
Normally this would be a compile time error, but using typeid can turn this into a runtime error.
https://docs.rs/assert-type-eq/0.1.0/assert_type_eq/ allows you to assert that two types are the same, forcing a compile time error for this scenario.