-
Notifications
You must be signed in to change notification settings - Fork 10
Description
I may be misusing the feature, but I cannot make it working.
I am referring to the FUNCTOR template parameter in:
template<typename MANAGER, uint8_t REGISTER, typename T, typename FUNCTOR = functor::Identity> class TReadRegisterFuture
It appears only compiling when both FUNCTOR::ARG_TYPE and FUNCTOR::RES_TYPE types are related (when a cast is possible). I am not able to compile the code when both types are not related (and that's what I thought the functor was in the first place - to make this conversion possible).
Looking at the code in the ReadRegisterFuture template (i2c_device_utilities.h) I cannot see how it is possible for it to work.
Apologies for raising this if this is all OK and I simply missed something. Unfortunately, there is no example showing a case like mine - all existing ones convert types one-to-one.