Is there a reason why
Eq are not
implemented for function which have a parameter
with a lifetime valid for any lifetime.
for <'a> fn(&'a u32) or short
does not implement
I have a number of validation function, which are meant to be defined statically (e.g. through a macro, outside of the crate). And I intended to store them in a HashSet, as it is quite likely that the same function is added multiple times.
a workaround is to use a
(or whatever your function types is) and to fill it like
map.insert(func as usize, func).