The compiler (version 1.68.2) issues an error which (after a little sanitization) contains
help: the trait `Sync` is not implemented for `dyn for<'a> Fn(&'a [A]) -> Option<B>`
= note: required for `std::ptr::Unique<dyn for<'a> Fn(&'a [A]) -> Option<B>>` to implement `Sync`
= note: required because it appears within the type `Box<dyn for<'a> Fn(&'a [A]) -> Option<B>>`
This is the first time that I consciously see std::ptr::Unique. A search suggests that it is something that was unstable and was removed (at least under that name) 4 years ago.
What do I need to know about std::ptr::Unique in order to write Rust using modern tooling in 2023?
I also stumbled upon Unique at some point and it also confused me. Maybe it would be better to not expose it in error messages if it's a (perma-unstable?) implementation detail?
As far as the compiler is concerned, it's no different from mentioning that Vec<my_crate::Foo> is !Sync because my_crate::Foo is !Sync. The std::ptr::Unique type is just another private item which is contributing to the error.