Patrik Stridvall ps@leissner.se writes:
So the question is: Should we use the FORWARD_WM_* macros to avoid typecasts (or rather avoid visable typecast) or should we not? If not how should we fix the problems?
I think it's better to avoid that. Hiding the typecasts in the macros doesn't really make things cleaner IMO. This is a case where the API design forces us to use a typecast, so we might as well make it explicit.
Note that for the specific case of WM_GET/SETTEXT, it would be much better to use Get/SetWindowText which will do correct type checks. But for messages that don't have a corresponding function we have to do the typecast.